[cloud][docs] Add a cloudformation_facts example (#31964)

This commit is contained in:
Prasad Katti 2017-10-26 05:29:10 -07:00 committed by Ryan Brown
parent 838c1ba6c7
commit 13807e7ee8

View file

@ -69,6 +69,17 @@ EXAMPLES = '''
- debug:
msg: "{{ ansible_facts['cloudformation']['my-cloudformation-stack'] }}"
# Get stack outputs, when you have the stack name available as a fact
- set_fact:
stack_name: my-awesome-stack
- cloudformation_facts:
stack_name: "{{ stack_name }}"
register: my_stack
- debug:
msg: "{{ my_stack.ansible_facts.cloudformation[stack_name].stack_outputs }}"
# Get all stack information about a stack
- cloudformation_facts:
stack_name: my-cloudformation-stack