123456789101112131415161718192021222324252627282930313233343536 |
- ---
- - name: Make temp directory for templates
- command: mktemp -d /tmp/ansible-XXXXXX
- register: mktemp
- changed_when: False
- - name: Copy templates to temp directory
- copy:
- src: "{{ item }}"
- dest: "{{ mktemp.stdout }}/{{ item | basename }}"
- with_fileglob:
- - "files/*.yaml"
- - name: Update the image tag
- run_once: true
- yedit:
- src: "{{ mktemp.stdout }}/openshift-bootstrap-images.yaml"
- key: 'tag.from.name'
- value: "{{ osn_image }}"
- # TODO: temporary until we fix apply for image stream tags
- - name: Remove the image stream tag
- shell: >
- {{ openshift_client_binary }} delete -n openshift-infra istag node:v3.10 --ignore-not-found
- - name: Apply the config
- run_once: true
- shell: >
- {{ openshift_client_binary }} apply -f "{{ mktemp.stdout }}"
- - name: Remove temp directory
- run_once: true
- file:
- state: absent
- name: "{{ mktemp.stdout }}"
- changed_when: False
|