From 3973eb4c3041db3e686e28d05191bfeb6663b934 Mon Sep 17 00:00:00 2001 From: Dag Wieers Date: Fri, 30 Mar 2018 09:27:45 +0200 Subject: [PATCH] Added an example using a templated payload file +label: docsite_pr --- lib/ansible/modules/network/aci/aci_rest.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/ansible/modules/network/aci/aci_rest.py b/lib/ansible/modules/network/aci/aci_rest.py index 4c6c958d9c..fda2674c05 100644 --- a/lib/ansible/modules/network/aci/aci_rest.py +++ b/lib/ansible/modules/network/aci/aci_rest.py @@ -74,6 +74,16 @@ EXAMPLES = r''' src: /home/cisco/ansible/aci/configs/aci_config.xml delegate_to: localhost +- name: Add a tenant from a templated payload file from templates/ + aci_rest: + host: apic + username: admin + private_key: pki/admin.key + method: post + path: /api/mo/uni.xml + content: "{{ lookup('template', 'aci/tenant.xml.j2') }}" + delegate_to: localhost + - name: Add a tenant using inline YAML aci_rest: host: apic