Skip to content
Browse files
Better management of inventory to pick up tags
Added a meta task to rebuild inventory. This causes the script to
be run again and pick up the tags for the recently provisioned ec2
instances, so that the tags can be used as variables later in
  • Loading branch information
skoranda committed Nov 9, 2019
1 parent 42233fb commit 00d0782b6cf1c7aaf35ea35c2fe709b5801231ac
Showing 2 changed files with 5 additions and 1 deletion.
@@ -118,6 +118,7 @@ cache_path = ~/.ansible/tmp
# seconds, a new API call will be made, and the cache file will be updated.
# To disable the cache, set this value to 0
#cache_max_age = 300
cache_max_age = 0

# Organize groups into a nested/hierarchy instead of a flat namespace.
nested_groups = False
@@ -236,8 +236,11 @@
overwrite: yes
wait: no
loop: "{{ training_nodes.results }}"

- name: Refresh inventory to pick up ec2 tags
meta: refresh_inventory

- hosts: ssh_training_node_hosts
- hosts: tag_role_comanage_registry
become: yes
gather_facts: True
strategy: free

0 comments on commit 00d0782

Please sign in to comment.