Last active
December 9, 2015 18:08
-
-
Save robbwagoner/4ac02558b088c6c55f69 to your computer and use it in GitHub Desktop.
ec2-facts Ansible role with derived facts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
ec2_facts_vpc_network_prefix: "172." | |
# derived facts | |
ansible_ec2_in_vpc: no |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- ec2_facts: | |
- set_fact: | |
ansible_ec2_in_vpc: yes | |
when: ansible_ec2_local_ipv4 | match(ec2_facts_vpc_network_prefix) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment