Переглянути джерело

Merge pull request #193 from mwoodson/ec2_vars

added destination_vars to ec2.ini
Matt Woodson 10 роки тому
батько
коміт
e177997ba3
1 змінених файлів з 14 додано та 0 видалено
  1. 14 0
      roles/openshift_ansible_inventory/tasks/main.yml

+ 14 - 0
roles/openshift_ansible_inventory/tasks/main.yml

@@ -29,3 +29,17 @@
     backrefs: yes
     regexp: '^(hostfile|inventory)( *)='
     line: '\1\2= /etc/ansible/inventory'
+
+- name: setting ec2.ini destination_format
+  lineinfile:
+    dest: /usr/share/ansible/inventory/aws/ec2.ini
+    regexp: '^destination_format *='
+    line: "destination_format = {{ oo_ec2_destination_format }}"
+  when: oo_ec2_destination_format is defined
+
+- name: setting ec2.ini destination_format_tags
+  lineinfile:
+    dest: /usr/share/ansible/inventory/aws/ec2.ini
+    regexp: '^destination_format_tags *='
+    line: "destination_format_tags = {{ oo_ec2_destination_format_tags }}"
+  when: oo_ec2_destination_format_tags is defined