Fix loop var;Fix template vars
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Danny Bessems 2022-11-07 01:57:30 +01:00
parent 09c4a17050
commit 22c06e2388

View File

@ -71,20 +71,17 @@
loop_control: loop_control:
label: "{{ item.url | basename }}" label: "{{ item.url | basename }}"
- debug: - name: Parse manifests
var: clusterapi_manifests ansible.builtin.shell:
# - name: Parse manifests cmd: cat {{ item.dest }} | yq --no-doc eval '.. | .image? | select(.)' | awk '!/ /' | sort
# ansible.builtin.shell: register: parsedmanifests
# cmd: cat {{ item | basename }} | yq --no-doc eval '.. | .image? | select(.)' | awk '!/ /' | sort loop: "{{ clusterapi_manifests.results | sort }}"
# chdir: /opt/metacluster/manifests loop_control:
# register: parsedmanifests label: "{{ item | basename }}"
# loop: "{{ clusterapi_manifests.stdout_lines | sort }}"
# loop_control:
# label: "{{ item | basename }}"
# - name: Store container images - name: Store container images
# ansible.builtin.set_fact: ansible.builtin.set_fact:
# clusterapi_containerimages: "{{ parsedmanifests | json_query('results[*].stdout') }}" clusterapi_containerimages: "{{ parsedmanifests | json_query('results[*].stdout') }}"
- name: Configure clusterctl - name: Configure clusterctl
ansible.builtin.template: ansible.builtin.template:
@ -93,12 +90,12 @@
vars: vars:
_template: _template:
hv: hv:
fqdn: vapp['hv.fqdn'] fqdn: "{{ vapp['hv.fqdn'] }}"
username: vapp['hv.username'] username: "{{ vapp['hv.username'] }}"
password: vapp['hv.password'] password: "{{ vapp['hv.password'] }}"
version: version:
base: components.clusterapi.manifest.version.base base: "{{ components.clusterapi.manifest.version.base }}"
infrastructure_vsphere: components.clusterapi.manifest.version.infrastructure_vsphere infrastructure_vsphere: "{{ components.clusterapi.manifest.version.infrastructure_vsphere }}"
- name: Parse helm charts for container images - name: Parse helm charts for container images
ansible.builtin.shell: ansible.builtin.shell: