From d7927502fed8ad19ef5d27f688e0a1cc17b60a4b Mon Sep 17 00:00:00 2001 From: Bartek Grzybowski Date: Thu, 8 Apr 2021 16:41:16 +0200 Subject: [MOLECULE 3.3.0] Update converge playbook file names In 3.x.x version family of Molecule the 'playbook.yml' file for 'converge' action has changed to 'converge.yml'. Ref.: https://github.com/ansible-community/molecule/issues/2560 Change-Id: I8710ebd5710237be138f2aff8943d6c949058dbd Issue-ID: OOM-2722 Signed-off-by: Bartek Grzybowski --- .../application/molecule/custom_role/molecule.yml | 2 +- .../application/molecule/default/converge.yml | 5 +++ .../application/molecule/default/playbook.yml | 5 --- .../roles/application/molecule/helm3/molecule.yml | 2 +- .../roles/application/molecule/ubuntu/molecule.yml | 2 +- .../certificates/molecule/default/converge.yml | 20 +++++++++++ .../certificates/molecule/default/playbook.yml | 20 ----------- .../certificates/molecule/ubuntu/molecule.yml | 2 +- .../chartmuseum/molecule/default/converge.yml | 5 +++ .../chartmuseum/molecule/default/playbook.yml | 5 --- .../roles/chartmuseum/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/chrony/molecule/default/converge.yml | 14 ++++++++ ansible/roles/chrony/molecule/default/playbook.yml | 14 -------- .../molecule/external_time_source/converge.yml | 10 ++++++ .../molecule/external_time_source/playbook.yml | 10 ------ .../external_time_source_ubuntu/molecule.yml | 2 +- ansible/roles/chrony/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/dns/molecule/default/converge.yml | 5 +++ ansible/roles/dns/molecule/default/playbook.yml | 5 --- ansible/roles/dns/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/docker/molecule/default/converge.yml | 5 +++ ansible/roles/docker/molecule/default/playbook.yml | 5 --- ansible/roles/docker/molecule/ubuntu/molecule.yml | 2 +- .../roles/firewall/molecule/default/converge.yml | 5 +++ .../roles/firewall/molecule/default/playbook.yml | 5 --- ansible/roles/helm/molecule/default/converge.yml | 10 ++++++ ansible/roles/helm/molecule/default/playbook.yml | 10 ------ ansible/roles/helm/molecule/helm3/converge.yml | 1 + ansible/roles/helm/molecule/helm3/playbook.yml | 1 - ansible/roles/helm/molecule/ubuntu/molecule.yml | 2 +- .../roles/kubectl/molecule/default/converge.yml | 5 +++ .../roles/kubectl/molecule/default/playbook.yml | 5 --- ansible/roles/kubectl/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/nexus/molecule/default/converge.yml | 11 ++++++ ansible/roles/nexus/molecule/default/playbook.yml | 11 ------ ansible/roles/nexus/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/nfs/molecule/default/converge.yml | 5 +++ ansible/roles/nfs/molecule/default/playbook.yml | 5 --- ansible/roles/nfs/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/nginx/molecule/default/converge.yml | 5 +++ ansible/roles/nginx/molecule/default/playbook.yml | 5 --- ansible/roles/nginx/molecule/ubuntu/molecule.yml | 2 +- .../molecule/default/converge.yml | 5 +++ .../molecule/default/playbook.yml | 5 --- .../molecule/ubuntu/molecule.yml | 2 +- .../molecule/default/converge.yml | 5 +++ .../molecule/default/playbook.yml | 5 --- .../molecule/ubuntu/molecule.yml | 2 +- .../roles/rancher/molecule/default/converge.yml | 28 ++++++++++++++++ .../roles/rancher/molecule/default/playbook.yml | 28 ---------------- .../resource-data/molecule/default/converge.yml | 6 ++++ .../resource-data/molecule/default/playbook.yml | 6 ---- .../resource-data/molecule/ubuntu/molecule.yml | 2 +- ansible/roles/rke/molecule/default/converge.yml | 39 ++++++++++++++++++++++ ansible/roles/rke/molecule/default/playbook.yml | 39 ---------------------- .../roles/rke/molecule/etcd_storage/molecule.yml | 2 +- ansible/roles/setup/molecule/default/converge.yml | 5 +++ ansible/roles/setup/molecule/default/playbook.yml | 5 --- ansible/roles/setup/molecule/ubuntu/molecule.yml | 2 +- .../roles/vncserver/molecule/default/converge.yml | 5 +++ .../roles/vncserver/molecule/default/playbook.yml | 5 --- .../roles/vncserver/molecule/ubuntu/molecule.yml | 2 +- .../molecule/default/converge.yml | 11 ++++++ .../molecule/default/playbook.yml | 11 ------ .../play-resources/molecule/default/converge.yml | 8 +++++ .../play-resources/molecule/default/playbook.yml | 8 ----- .../test/play-resources/molecule/nfs/converge.yml | 8 +++++ .../test/play-resources/molecule/nfs/playbook.yml | 8 ----- .../test/play-rke/molecule/default/converge.yml | 11 ++++++ .../test/play-rke/molecule/default/playbook.yml | 11 ------ ansible/test/play-rke/molecule/helm3/converge.yml | 1 + ansible/test/play-rke/molecule/helm3/playbook.yml | 1 - 72 files changed, 258 insertions(+), 258 deletions(-) create mode 100644 ansible/roles/application/molecule/default/converge.yml delete mode 100644 ansible/roles/application/molecule/default/playbook.yml create mode 100644 ansible/roles/certificates/molecule/default/converge.yml delete mode 100644 ansible/roles/certificates/molecule/default/playbook.yml create mode 100644 ansible/roles/chartmuseum/molecule/default/converge.yml delete mode 100644 ansible/roles/chartmuseum/molecule/default/playbook.yml create mode 100644 ansible/roles/chrony/molecule/default/converge.yml delete mode 100644 ansible/roles/chrony/molecule/default/playbook.yml create mode 100644 ansible/roles/chrony/molecule/external_time_source/converge.yml delete mode 100644 ansible/roles/chrony/molecule/external_time_source/playbook.yml create mode 100644 ansible/roles/dns/molecule/default/converge.yml delete mode 100644 ansible/roles/dns/molecule/default/playbook.yml create mode 100644 ansible/roles/docker/molecule/default/converge.yml delete mode 100644 ansible/roles/docker/molecule/default/playbook.yml create mode 100644 ansible/roles/firewall/molecule/default/converge.yml delete mode 100644 ansible/roles/firewall/molecule/default/playbook.yml create mode 100644 ansible/roles/helm/molecule/default/converge.yml delete mode 100644 ansible/roles/helm/molecule/default/playbook.yml create mode 120000 ansible/roles/helm/molecule/helm3/converge.yml delete mode 120000 ansible/roles/helm/molecule/helm3/playbook.yml create mode 100644 ansible/roles/kubectl/molecule/default/converge.yml delete mode 100644 ansible/roles/kubectl/molecule/default/playbook.yml create mode 100644 ansible/roles/nexus/molecule/default/converge.yml delete mode 100644 ansible/roles/nexus/molecule/default/playbook.yml create mode 100644 ansible/roles/nfs/molecule/default/converge.yml delete mode 100644 ansible/roles/nfs/molecule/default/playbook.yml create mode 100644 ansible/roles/nginx/molecule/default/converge.yml delete mode 100644 ansible/roles/nginx/molecule/default/playbook.yml create mode 100755 ansible/roles/package-repository-check/molecule/default/converge.yml delete mode 100755 ansible/roles/package-repository-check/molecule/default/playbook.yml create mode 100644 ansible/roles/package-repository/molecule/default/converge.yml delete mode 100644 ansible/roles/package-repository/molecule/default/playbook.yml create mode 100644 ansible/roles/rancher/molecule/default/converge.yml delete mode 100644 ansible/roles/rancher/molecule/default/playbook.yml create mode 100644 ansible/roles/resource-data/molecule/default/converge.yml delete mode 100644 ansible/roles/resource-data/molecule/default/playbook.yml create mode 100644 ansible/roles/rke/molecule/default/converge.yml delete mode 100644 ansible/roles/rke/molecule/default/playbook.yml create mode 100644 ansible/roles/setup/molecule/default/converge.yml delete mode 100644 ansible/roles/setup/molecule/default/playbook.yml create mode 100644 ansible/roles/vncserver/molecule/default/converge.yml delete mode 100644 ansible/roles/vncserver/molecule/default/playbook.yml create mode 100644 ansible/test/play-infrastructure/molecule/default/converge.yml delete mode 100644 ansible/test/play-infrastructure/molecule/default/playbook.yml create mode 100644 ansible/test/play-resources/molecule/default/converge.yml delete mode 100644 ansible/test/play-resources/molecule/default/playbook.yml create mode 100644 ansible/test/play-resources/molecule/nfs/converge.yml delete mode 100644 ansible/test/play-resources/molecule/nfs/playbook.yml create mode 100644 ansible/test/play-rke/molecule/default/converge.yml delete mode 100644 ansible/test/play-rke/molecule/default/playbook.yml create mode 120000 ansible/test/play-rke/molecule/helm3/converge.yml delete mode 120000 ansible/test/play-rke/molecule/helm3/playbook.yml (limited to 'ansible') diff --git a/ansible/roles/application/molecule/custom_role/molecule.yml b/ansible/roles/application/molecule/custom_role/molecule.yml index 6000e0e7..733ad188 100644 --- a/ansible/roles/application/molecule/custom_role/molecule.yml +++ b/ansible/roles/application/molecule/custom_role/molecule.yml @@ -35,7 +35,7 @@ provisioner: helm_version: v2 playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml scenario: name: custom_role diff --git a/ansible/roles/application/molecule/default/converge.yml b/ansible/roles/application/molecule/default/converge.yml new file mode 100644 index 00000000..4121f124 --- /dev/null +++ b/ansible/roles/application/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Helm charts available + hosts: all + roles: + - application diff --git a/ansible/roles/application/molecule/default/playbook.yml b/ansible/roles/application/molecule/default/playbook.yml deleted file mode 100644 index 4121f124..00000000 --- a/ansible/roles/application/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Helm charts available - hosts: all - roles: - - application diff --git a/ansible/roles/application/molecule/helm3/molecule.yml b/ansible/roles/application/molecule/helm3/molecule.yml index 50e9cb84..8ca5fca1 100644 --- a/ansible/roles/application/molecule/helm3/molecule.yml +++ b/ansible/roles/application/molecule/helm3/molecule.yml @@ -33,7 +33,7 @@ provisioner: helm_version: v3 playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml scenario: name: helm3 diff --git a/ansible/roles/application/molecule/ubuntu/molecule.yml b/ansible/roles/application/molecule/ubuntu/molecule.yml index aa8151fa..42523388 100644 --- a/ansible/roles/application/molecule/ubuntu/molecule.yml +++ b/ansible/roles/application/molecule/ubuntu/molecule.yml @@ -34,7 +34,7 @@ provisioner: helm_version: v2 playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml scenario: name: ubuntu diff --git a/ansible/roles/certificates/molecule/default/converge.yml b/ansible/roles/certificates/molecule/default/converge.yml new file mode 100644 index 00000000..13583ebb --- /dev/null +++ b/ansible/roles/certificates/molecule/default/converge.yml @@ -0,0 +1,20 @@ +--- +- name: Infra + hosts: infrastructure + handlers: + - name: Restart Docker + debug: msg="Docker restart called" + roles: + - certificates + +- name: Kube + hosts: kubernetes + handlers: + - name: Restart Docker + debug: msg="Docker restart called" + tasks: + - include_role: + name: certificates + tasks_from: upload_root_ca.yml + vars: + certificates_local_dir: certs diff --git a/ansible/roles/certificates/molecule/default/playbook.yml b/ansible/roles/certificates/molecule/default/playbook.yml deleted file mode 100644 index 13583ebb..00000000 --- a/ansible/roles/certificates/molecule/default/playbook.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -- name: Infra - hosts: infrastructure - handlers: - - name: Restart Docker - debug: msg="Docker restart called" - roles: - - certificates - -- name: Kube - hosts: kubernetes - handlers: - - name: Restart Docker - debug: msg="Docker restart called" - tasks: - - include_role: - name: certificates - tasks_from: upload_root_ca.yml - vars: - certificates_local_dir: certs diff --git a/ansible/roles/certificates/molecule/ubuntu/molecule.yml b/ansible/roles/certificates/molecule/ubuntu/molecule.yml index 9708bd9b..aa519907 100644 --- a/ansible/roles/certificates/molecule/ubuntu/molecule.yml +++ b/ansible/roles/certificates/molecule/ubuntu/molecule.yml @@ -30,7 +30,7 @@ provisioner: ANSIBLE_ROLES_PATH: ../../../../test/roles ANSIBLE_LIBRARY: ../../../../library playbooks: - converge: ../default/playbook.yml + converge: ../default/converge.yml inventory: links: group_vars: ../../../../group_vars/ diff --git a/ansible/roles/chartmuseum/molecule/default/converge.yml b/ansible/roles/chartmuseum/molecule/default/converge.yml new file mode 100644 index 00000000..2694582a --- /dev/null +++ b/ansible/roles/chartmuseum/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - chartmuseum diff --git a/ansible/roles/chartmuseum/molecule/default/playbook.yml b/ansible/roles/chartmuseum/molecule/default/playbook.yml deleted file mode 100644 index 2694582a..00000000 --- a/ansible/roles/chartmuseum/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - chartmuseum diff --git a/ansible/roles/chartmuseum/molecule/ubuntu/molecule.yml b/ansible/roles/chartmuseum/molecule/ubuntu/molecule.yml index 307988ad..8b50ec54 100644 --- a/ansible/roles/chartmuseum/molecule/ubuntu/molecule.yml +++ b/ansible/roles/chartmuseum/molecule/ubuntu/molecule.yml @@ -28,7 +28,7 @@ provisioner: group_vars: ../../../../group_vars playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml scenario: name: ubuntu verifier: diff --git a/ansible/roles/chrony/molecule/default/converge.yml b/ansible/roles/chrony/molecule/default/converge.yml new file mode 100644 index 00000000..717d0f39 --- /dev/null +++ b/ansible/roles/chrony/molecule/default/converge.yml @@ -0,0 +1,14 @@ +--- +- name: Converge infrastructure hosts + hosts: infrastructure + tasks: + - name: Set cluster_ip fact + set_fact: + cluster_ip: "{{ ansible_default_ipv4.address }}" + roles: + - chrony + +- name: Converge kubernetes hosts + hosts: kubernetes + roles: + - chrony diff --git a/ansible/roles/chrony/molecule/default/playbook.yml b/ansible/roles/chrony/molecule/default/playbook.yml deleted file mode 100644 index 717d0f39..00000000 --- a/ansible/roles/chrony/molecule/default/playbook.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -- name: Converge infrastructure hosts - hosts: infrastructure - tasks: - - name: Set cluster_ip fact - set_fact: - cluster_ip: "{{ ansible_default_ipv4.address }}" - roles: - - chrony - -- name: Converge kubernetes hosts - hosts: kubernetes - roles: - - chrony diff --git a/ansible/roles/chrony/molecule/external_time_source/converge.yml b/ansible/roles/chrony/molecule/external_time_source/converge.yml new file mode 100644 index 00000000..7dccfc35 --- /dev/null +++ b/ansible/roles/chrony/molecule/external_time_source/converge.yml @@ -0,0 +1,10 @@ +--- +- name: Converge infrastructure hosts + hosts: infrastructure + roles: + - chrony + +- name: Converge kubernetes hosts + hosts: kubernetes + roles: + - chrony diff --git a/ansible/roles/chrony/molecule/external_time_source/playbook.yml b/ansible/roles/chrony/molecule/external_time_source/playbook.yml deleted file mode 100644 index 7dccfc35..00000000 --- a/ansible/roles/chrony/molecule/external_time_source/playbook.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- name: Converge infrastructure hosts - hosts: infrastructure - roles: - - chrony - -- name: Converge kubernetes hosts - hosts: kubernetes - roles: - - chrony diff --git a/ansible/roles/chrony/molecule/external_time_source_ubuntu/molecule.yml b/ansible/roles/chrony/molecule/external_time_source_ubuntu/molecule.yml index 0fbef39b..8bdccee1 100644 --- a/ansible/roles/chrony/molecule/external_time_source_ubuntu/molecule.yml +++ b/ansible/roles/chrony/molecule/external_time_source_ubuntu/molecule.yml @@ -41,7 +41,7 @@ provisioner: timezone: Europe/Warsaw playbooks: prepare: ../default/prepare.yml - converge: ../external_time_source/playbook.yml + converge: ../external_time_source/converge.yml verifier: name: testinfra options: diff --git a/ansible/roles/chrony/molecule/ubuntu/molecule.yml b/ansible/roles/chrony/molecule/ubuntu/molecule.yml index a92dfa3b..32aef6fb 100644 --- a/ansible/roles/chrony/molecule/ubuntu/molecule.yml +++ b/ansible/roles/chrony/molecule/ubuntu/molecule.yml @@ -33,7 +33,7 @@ provisioner: ANSIBLE_ROLES_PATH: ../../../../test/roles playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml verifier: name: testinfra options: diff --git a/ansible/roles/dns/molecule/default/converge.yml b/ansible/roles/dns/molecule/default/converge.yml new file mode 100644 index 00000000..8754f8b0 --- /dev/null +++ b/ansible/roles/dns/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - role: dns diff --git a/ansible/roles/dns/molecule/default/playbook.yml b/ansible/roles/dns/molecule/default/playbook.yml deleted file mode 100644 index 8754f8b0..00000000 --- a/ansible/roles/dns/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - role: dns diff --git a/ansible/roles/dns/molecule/ubuntu/molecule.yml b/ansible/roles/dns/molecule/ubuntu/molecule.yml index 5621b733..ae763c22 100644 --- a/ansible/roles/dns/molecule/ubuntu/molecule.yml +++ b/ansible/roles/dns/molecule/ubuntu/molecule.yml @@ -25,7 +25,7 @@ provisioner: ANSIBLE_LIBRARY: ../../../../library playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml inventory: host_vars: diff --git a/ansible/roles/docker/molecule/default/converge.yml b/ansible/roles/docker/molecule/default/converge.yml new file mode 100644 index 00000000..7384ae27 --- /dev/null +++ b/ansible/roles/docker/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - role: docker diff --git a/ansible/roles/docker/molecule/default/playbook.yml b/ansible/roles/docker/molecule/default/playbook.yml deleted file mode 100644 index 7384ae27..00000000 --- a/ansible/roles/docker/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - role: docker diff --git a/ansible/roles/docker/molecule/ubuntu/molecule.yml b/ansible/roles/docker/molecule/ubuntu/molecule.yml index 751782af..a4705a14 100644 --- a/ansible/roles/docker/molecule/ubuntu/molecule.yml +++ b/ansible/roles/docker/molecule/ubuntu/molecule.yml @@ -25,7 +25,7 @@ provisioner: name: ansible playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml env: ANSIBLE_ROLES_PATH: ../../../../test/roles ANSIBLE_LIBRARY: ../../../../library diff --git a/ansible/roles/firewall/molecule/default/converge.yml b/ansible/roles/firewall/molecule/default/converge.yml new file mode 100644 index 00000000..73b20eac --- /dev/null +++ b/ansible/roles/firewall/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - role: firewall diff --git a/ansible/roles/firewall/molecule/default/playbook.yml b/ansible/roles/firewall/molecule/default/playbook.yml deleted file mode 100644 index 73b20eac..00000000 --- a/ansible/roles/firewall/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - role: firewall diff --git a/ansible/roles/helm/molecule/default/converge.yml b/ansible/roles/helm/molecule/default/converge.yml new file mode 100644 index 00000000..0f3fbc27 --- /dev/null +++ b/ansible/roles/helm/molecule/default/converge.yml @@ -0,0 +1,10 @@ +--- +- name: Converge + hosts: all + pre_tasks: + - name: Include infrastructure group variables + include_vars: ../../../../group_vars/infrastructure.yml + - name: Include test scenario variables + include_vars: vars.yml + roles: + - helm diff --git a/ansible/roles/helm/molecule/default/playbook.yml b/ansible/roles/helm/molecule/default/playbook.yml deleted file mode 100644 index 0f3fbc27..00000000 --- a/ansible/roles/helm/molecule/default/playbook.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- name: Converge - hosts: all - pre_tasks: - - name: Include infrastructure group variables - include_vars: ../../../../group_vars/infrastructure.yml - - name: Include test scenario variables - include_vars: vars.yml - roles: - - helm diff --git a/ansible/roles/helm/molecule/helm3/converge.yml b/ansible/roles/helm/molecule/helm3/converge.yml new file mode 120000 index 00000000..73cb8dad --- /dev/null +++ b/ansible/roles/helm/molecule/helm3/converge.yml @@ -0,0 +1 @@ +../default/converge.yml \ No newline at end of file diff --git a/ansible/roles/helm/molecule/helm3/playbook.yml b/ansible/roles/helm/molecule/helm3/playbook.yml deleted file mode 120000 index a3e26797..00000000 --- a/ansible/roles/helm/molecule/helm3/playbook.yml +++ /dev/null @@ -1 +0,0 @@ -../default/playbook.yml \ No newline at end of file diff --git a/ansible/roles/helm/molecule/ubuntu/molecule.yml b/ansible/roles/helm/molecule/ubuntu/molecule.yml index 9a972881..c4354e88 100644 --- a/ansible/roles/helm/molecule/ubuntu/molecule.yml +++ b/ansible/roles/helm/molecule/ubuntu/molecule.yml @@ -20,7 +20,7 @@ provisioner: ANSIBLE_LIBRARY: ../../../../library playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml inventory: group_vars: all: diff --git a/ansible/roles/kubectl/molecule/default/converge.yml b/ansible/roles/kubectl/molecule/default/converge.yml new file mode 100644 index 00000000..ab9c08a8 --- /dev/null +++ b/ansible/roles/kubectl/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - kubectl diff --git a/ansible/roles/kubectl/molecule/default/playbook.yml b/ansible/roles/kubectl/molecule/default/playbook.yml deleted file mode 100644 index ab9c08a8..00000000 --- a/ansible/roles/kubectl/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - kubectl diff --git a/ansible/roles/kubectl/molecule/ubuntu/molecule.yml b/ansible/roles/kubectl/molecule/ubuntu/molecule.yml index e9422fd2..56edda13 100644 --- a/ansible/roles/kubectl/molecule/ubuntu/molecule.yml +++ b/ansible/roles/kubectl/molecule/ubuntu/molecule.yml @@ -23,7 +23,7 @@ provisioner: ANSIBLE_LIBRARY: ../../../../library playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml inventory: group_vars: all: diff --git a/ansible/roles/nexus/molecule/default/converge.yml b/ansible/roles/nexus/molecule/default/converge.yml new file mode 100644 index 00000000..e10ea55b --- /dev/null +++ b/ansible/roles/nexus/molecule/default/converge.yml @@ -0,0 +1,11 @@ +--- +- name: Converge + hosts: all + vars: + nexus_port: ":8081" + nexus3_published_ports: + - "{{ '8081' + nexus_port }}" + nexus_url_scheme: http + populate_nexus: true + roles: + - nexus diff --git a/ansible/roles/nexus/molecule/default/playbook.yml b/ansible/roles/nexus/molecule/default/playbook.yml deleted file mode 100644 index e10ea55b..00000000 --- a/ansible/roles/nexus/molecule/default/playbook.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -- name: Converge - hosts: all - vars: - nexus_port: ":8081" - nexus3_published_ports: - - "{{ '8081' + nexus_port }}" - nexus_url_scheme: http - populate_nexus: true - roles: - - nexus diff --git a/ansible/roles/nexus/molecule/ubuntu/molecule.yml b/ansible/roles/nexus/molecule/ubuntu/molecule.yml index d882633a..6925a9d4 100644 --- a/ansible/roles/nexus/molecule/ubuntu/molecule.yml +++ b/ansible/roles/nexus/molecule/ubuntu/molecule.yml @@ -27,7 +27,7 @@ provisioner: group_vars: ../../../../group_vars playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml scenario: name: ubuntu diff --git a/ansible/roles/nfs/molecule/default/converge.yml b/ansible/roles/nfs/molecule/default/converge.yml new file mode 100644 index 00000000..37aad5b9 --- /dev/null +++ b/ansible/roles/nfs/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - role: nfs diff --git a/ansible/roles/nfs/molecule/default/playbook.yml b/ansible/roles/nfs/molecule/default/playbook.yml deleted file mode 100644 index 37aad5b9..00000000 --- a/ansible/roles/nfs/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - role: nfs diff --git a/ansible/roles/nfs/molecule/ubuntu/molecule.yml b/ansible/roles/nfs/molecule/ubuntu/molecule.yml index 61728cde..4cc5fb55 100644 --- a/ansible/roles/nfs/molecule/ubuntu/molecule.yml +++ b/ansible/roles/nfs/molecule/ubuntu/molecule.yml @@ -45,7 +45,7 @@ provisioner: host_vars: ../default/host_vars playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml scenario: name: ubuntu verifier: diff --git a/ansible/roles/nginx/molecule/default/converge.yml b/ansible/roles/nginx/molecule/default/converge.yml new file mode 100644 index 00000000..431bb666 --- /dev/null +++ b/ansible/roles/nginx/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - nginx diff --git a/ansible/roles/nginx/molecule/default/playbook.yml b/ansible/roles/nginx/molecule/default/playbook.yml deleted file mode 100644 index 431bb666..00000000 --- a/ansible/roles/nginx/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - nginx diff --git a/ansible/roles/nginx/molecule/ubuntu/molecule.yml b/ansible/roles/nginx/molecule/ubuntu/molecule.yml index d882633a..6925a9d4 100644 --- a/ansible/roles/nginx/molecule/ubuntu/molecule.yml +++ b/ansible/roles/nginx/molecule/ubuntu/molecule.yml @@ -27,7 +27,7 @@ provisioner: group_vars: ../../../../group_vars playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml scenario: name: ubuntu diff --git a/ansible/roles/package-repository-check/molecule/default/converge.yml b/ansible/roles/package-repository-check/molecule/default/converge.yml new file mode 100755 index 00000000..7dd80c77 --- /dev/null +++ b/ansible/roles/package-repository-check/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Activate repository on node host + hosts: all + roles: + - package-repository-check diff --git a/ansible/roles/package-repository-check/molecule/default/playbook.yml b/ansible/roles/package-repository-check/molecule/default/playbook.yml deleted file mode 100755 index 7dd80c77..00000000 --- a/ansible/roles/package-repository-check/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Activate repository on node host - hosts: all - roles: - - package-repository-check diff --git a/ansible/roles/package-repository-check/molecule/ubuntu/molecule.yml b/ansible/roles/package-repository-check/molecule/ubuntu/molecule.yml index 23e7a61e..3a1cf7cd 100755 --- a/ansible/roles/package-repository-check/molecule/ubuntu/molecule.yml +++ b/ansible/roles/package-repository-check/molecule/ubuntu/molecule.yml @@ -22,7 +22,7 @@ platforms: provisioner: name: ansible playbooks: - converge: ../default/playbook.yml + converge: ../default/converge.yml inventory: host_vars: infrastructure-server: diff --git a/ansible/roles/package-repository/molecule/default/converge.yml b/ansible/roles/package-repository/molecule/default/converge.yml new file mode 100644 index 00000000..0b9c72f0 --- /dev/null +++ b/ansible/roles/package-repository/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - package-repository diff --git a/ansible/roles/package-repository/molecule/default/playbook.yml b/ansible/roles/package-repository/molecule/default/playbook.yml deleted file mode 100644 index 0b9c72f0..00000000 --- a/ansible/roles/package-repository/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - package-repository diff --git a/ansible/roles/package-repository/molecule/ubuntu/molecule.yml b/ansible/roles/package-repository/molecule/ubuntu/molecule.yml index f32e6490..23a45ef9 100644 --- a/ansible/roles/package-repository/molecule/ubuntu/molecule.yml +++ b/ansible/roles/package-repository/molecule/ubuntu/molecule.yml @@ -32,7 +32,7 @@ platforms: provisioner: name: ansible playbooks: - converge: ../default/playbook.yml + converge: ../default/converge.yml inventory: host_vars: infrastructure-server: diff --git a/ansible/roles/rancher/molecule/default/converge.yml b/ansible/roles/rancher/molecule/default/converge.yml new file mode 100644 index 00000000..afdbb4af --- /dev/null +++ b/ansible/roles/rancher/molecule/default/converge.yml @@ -0,0 +1,28 @@ +--- +- name: Converge rancher master + hosts: infrastructure + roles: + - prepare-common + - role: rancher + vars: + mode: server + +- name: Converge rancher agent + hosts: kubernetes + roles: + - prepare-common + - role: rancher + vars: + mode: agent + +- name: Wait for Kubernetes environment to be healthy + hosts: infrastructure + roles: + - role: rancher + vars: + mode: health + rancher_server_url: "http://{{ cluster_ip }}:8080" + # Do not get rancher cluster healthy in this env (to be checked), + # but it's enough in molecule test to verify we get this unhealthy response + rancher_cluster_health_state: unhealthy + rancher_cluster_health_check_retries: 40 diff --git a/ansible/roles/rancher/molecule/default/playbook.yml b/ansible/roles/rancher/molecule/default/playbook.yml deleted file mode 100644 index afdbb4af..00000000 --- a/ansible/roles/rancher/molecule/default/playbook.yml +++ /dev/null @@ -1,28 +0,0 @@ ---- -- name: Converge rancher master - hosts: infrastructure - roles: - - prepare-common - - role: rancher - vars: - mode: server - -- name: Converge rancher agent - hosts: kubernetes - roles: - - prepare-common - - role: rancher - vars: - mode: agent - -- name: Wait for Kubernetes environment to be healthy - hosts: infrastructure - roles: - - role: rancher - vars: - mode: health - rancher_server_url: "http://{{ cluster_ip }}:8080" - # Do not get rancher cluster healthy in this env (to be checked), - # but it's enough in molecule test to verify we get this unhealthy response - rancher_cluster_health_state: unhealthy - rancher_cluster_health_check_retries: 40 diff --git a/ansible/roles/resource-data/molecule/default/converge.yml b/ansible/roles/resource-data/molecule/default/converge.yml new file mode 100644 index 00000000..cdd9820f --- /dev/null +++ b/ansible/roles/resource-data/molecule/default/converge.yml @@ -0,0 +1,6 @@ +--- +- name: Converge + hosts: all + roles: + - setup + - resource-data diff --git a/ansible/roles/resource-data/molecule/default/playbook.yml b/ansible/roles/resource-data/molecule/default/playbook.yml deleted file mode 100644 index cdd9820f..00000000 --- a/ansible/roles/resource-data/molecule/default/playbook.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - setup - - resource-data diff --git a/ansible/roles/resource-data/molecule/ubuntu/molecule.yml b/ansible/roles/resource-data/molecule/ubuntu/molecule.yml index df886dbd..f60b02d5 100644 --- a/ansible/roles/resource-data/molecule/ubuntu/molecule.yml +++ b/ansible/roles/resource-data/molecule/ubuntu/molecule.yml @@ -42,7 +42,7 @@ provisioner: ANSIBLE_ROLES_PATH: ../../../../test/roles/ playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml scenario: name: ubuntu verifier: diff --git a/ansible/roles/rke/molecule/default/converge.yml b/ansible/roles/rke/molecule/default/converge.yml new file mode 100644 index 00000000..8db7aef5 --- /dev/null +++ b/ansible/roles/rke/molecule/default/converge.yml @@ -0,0 +1,39 @@ +--- +- name: "Set cluster_ip" + hosts: all + tasks: + - name: "Set cluster_ip fact" + set_fact: + cluster_ip: "{{ ansible_default_ipv4.address }}" + +- name: Configure etcd (RKE) + hosts: kubernetes-etcd + roles: + - role: rke + vars: + mode: etcd + +- name: Configure kubernetes cluster (RKE) + hosts: infrastructure + roles: + - role: rke + vars: + rke_dns: + provider: coredns + upstreamnameservers: + - 8.8.8.8 + mode: config + +- name: Prepare kubernetes hosts (RKE) + hosts: kubernetes + roles: + - role: rke + vars: + mode: node + +- name: Deploy kubernetes cluster (RKE) + hosts: infrastructure + roles: + - role: rke + vars: + mode: deploy diff --git a/ansible/roles/rke/molecule/default/playbook.yml b/ansible/roles/rke/molecule/default/playbook.yml deleted file mode 100644 index 8db7aef5..00000000 --- a/ansible/roles/rke/molecule/default/playbook.yml +++ /dev/null @@ -1,39 +0,0 @@ ---- -- name: "Set cluster_ip" - hosts: all - tasks: - - name: "Set cluster_ip fact" - set_fact: - cluster_ip: "{{ ansible_default_ipv4.address }}" - -- name: Configure etcd (RKE) - hosts: kubernetes-etcd - roles: - - role: rke - vars: - mode: etcd - -- name: Configure kubernetes cluster (RKE) - hosts: infrastructure - roles: - - role: rke - vars: - rke_dns: - provider: coredns - upstreamnameservers: - - 8.8.8.8 - mode: config - -- name: Prepare kubernetes hosts (RKE) - hosts: kubernetes - roles: - - role: rke - vars: - mode: node - -- name: Deploy kubernetes cluster (RKE) - hosts: infrastructure - roles: - - role: rke - vars: - mode: deploy diff --git a/ansible/roles/rke/molecule/etcd_storage/molecule.yml b/ansible/roles/rke/molecule/etcd_storage/molecule.yml index 9c9bb9b8..5c8a5732 100644 --- a/ansible/roles/rke/molecule/etcd_storage/molecule.yml +++ b/ansible/roles/rke/molecule/etcd_storage/molecule.yml @@ -46,7 +46,7 @@ provisioner: e: "app_data_path=/opt/onap" playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml destroy: ../default/destroy.yml scenario: name: etcd_storage diff --git a/ansible/roles/setup/molecule/default/converge.yml b/ansible/roles/setup/molecule/default/converge.yml new file mode 100644 index 00000000..19a90501 --- /dev/null +++ b/ansible/roles/setup/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - role: setup diff --git a/ansible/roles/setup/molecule/default/playbook.yml b/ansible/roles/setup/molecule/default/playbook.yml deleted file mode 100644 index 19a90501..00000000 --- a/ansible/roles/setup/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: all - roles: - - role: setup diff --git a/ansible/roles/setup/molecule/ubuntu/molecule.yml b/ansible/roles/setup/molecule/ubuntu/molecule.yml index d0cce594..0d9b9c9f 100644 --- a/ansible/roles/setup/molecule/ubuntu/molecule.yml +++ b/ansible/roles/setup/molecule/ubuntu/molecule.yml @@ -15,7 +15,7 @@ platforms: provisioner: name: ansible playbooks: - converge: ../default/playbook.yml + converge: ../default/converge.yml scenario: name: ubuntu verifier: diff --git a/ansible/roles/vncserver/molecule/default/converge.yml b/ansible/roles/vncserver/molecule/default/converge.yml new file mode 100644 index 00000000..1b253495 --- /dev/null +++ b/ansible/roles/vncserver/molecule/default/converge.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: infrastructure + roles: + - vncserver diff --git a/ansible/roles/vncserver/molecule/default/playbook.yml b/ansible/roles/vncserver/molecule/default/playbook.yml deleted file mode 100644 index 1b253495..00000000 --- a/ansible/roles/vncserver/molecule/default/playbook.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Converge - hosts: infrastructure - roles: - - vncserver diff --git a/ansible/roles/vncserver/molecule/ubuntu/molecule.yml b/ansible/roles/vncserver/molecule/ubuntu/molecule.yml index 38dbe7fd..604d7360 100644 --- a/ansible/roles/vncserver/molecule/ubuntu/molecule.yml +++ b/ansible/roles/vncserver/molecule/ubuntu/molecule.yml @@ -22,7 +22,7 @@ provisioner: name: ansible playbooks: prepare: ../default/prepare.yml - converge: ../default/playbook.yml + converge: ../default/converge.yml cleanup: ../default/cleanup.yml env: ANSIBLE_ROLES_PATH: ../../../../test/roles diff --git a/ansible/test/play-infrastructure/molecule/default/converge.yml b/ansible/test/play-infrastructure/molecule/default/converge.yml new file mode 100644 index 00000000..26b3c15d --- /dev/null +++ b/ansible/test/play-infrastructure/molecule/default/converge.yml @@ -0,0 +1,11 @@ +--- +- name: Common setup for all hosts + hosts: all + tasks: + - name: Set cluster_ip variable + set_fact: + cluster_ip: "{{ ansible_default_ipv4.address }}" + - name: Include variables + include_vars: vars.yml + +- import_playbook: ../../../../infrastructure.yml diff --git a/ansible/test/play-infrastructure/molecule/default/playbook.yml b/ansible/test/play-infrastructure/molecule/default/playbook.yml deleted file mode 100644 index 26b3c15d..00000000 --- a/ansible/test/play-infrastructure/molecule/default/playbook.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -- name: Common setup for all hosts - hosts: all - tasks: - - name: Set cluster_ip variable - set_fact: - cluster_ip: "{{ ansible_default_ipv4.address }}" - - name: Include variables - include_vars: vars.yml - -- import_playbook: ../../../../infrastructure.yml diff --git a/ansible/test/play-resources/molecule/default/converge.yml b/ansible/test/play-resources/molecule/default/converge.yml new file mode 100644 index 00000000..096077a2 --- /dev/null +++ b/ansible/test/play-resources/molecule/default/converge.yml @@ -0,0 +1,8 @@ +--- +- name: Initialize + hosts: all + tasks: + - name: Include variables + include_vars: vars.yml + +- import_playbook: ../../../../resources.yml diff --git a/ansible/test/play-resources/molecule/default/playbook.yml b/ansible/test/play-resources/molecule/default/playbook.yml deleted file mode 100644 index 096077a2..00000000 --- a/ansible/test/play-resources/molecule/default/playbook.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- name: Initialize - hosts: all - tasks: - - name: Include variables - include_vars: vars.yml - -- import_playbook: ../../../../resources.yml diff --git a/ansible/test/play-resources/molecule/nfs/converge.yml b/ansible/test/play-resources/molecule/nfs/converge.yml new file mode 100644 index 00000000..096077a2 --- /dev/null +++ b/ansible/test/play-resources/molecule/nfs/converge.yml @@ -0,0 +1,8 @@ +--- +- name: Initialize + hosts: all + tasks: + - name: Include variables + include_vars: vars.yml + +- import_playbook: ../../../../resources.yml diff --git a/ansible/test/play-resources/molecule/nfs/playbook.yml b/ansible/test/play-resources/molecule/nfs/playbook.yml deleted file mode 100644 index 096077a2..00000000 --- a/ansible/test/play-resources/molecule/nfs/playbook.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- name: Initialize - hosts: all - tasks: - - name: Include variables - include_vars: vars.yml - -- import_playbook: ../../../../resources.yml diff --git a/ansible/test/play-rke/molecule/default/converge.yml b/ansible/test/play-rke/molecule/default/converge.yml new file mode 100644 index 00000000..aa2e0df2 --- /dev/null +++ b/ansible/test/play-rke/molecule/default/converge.yml @@ -0,0 +1,11 @@ +--- +- name: Initialize + hosts: all + tasks: + - name: Set cluster_ip fact + set_fact: + cluster_ip: "{{ ansible_default_ipv4.address }}" + - name: Include variables + include_vars: vars.yml + +- import_playbook: ../../../../rke.yml diff --git a/ansible/test/play-rke/molecule/default/playbook.yml b/ansible/test/play-rke/molecule/default/playbook.yml deleted file mode 100644 index aa2e0df2..00000000 --- a/ansible/test/play-rke/molecule/default/playbook.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -- name: Initialize - hosts: all - tasks: - - name: Set cluster_ip fact - set_fact: - cluster_ip: "{{ ansible_default_ipv4.address }}" - - name: Include variables - include_vars: vars.yml - -- import_playbook: ../../../../rke.yml diff --git a/ansible/test/play-rke/molecule/helm3/converge.yml b/ansible/test/play-rke/molecule/helm3/converge.yml new file mode 120000 index 00000000..73cb8dad --- /dev/null +++ b/ansible/test/play-rke/molecule/helm3/converge.yml @@ -0,0 +1 @@ +../default/converge.yml \ No newline at end of file diff --git a/ansible/test/play-rke/molecule/helm3/playbook.yml b/ansible/test/play-rke/molecule/helm3/playbook.yml deleted file mode 120000 index a3e26797..00000000 --- a/ansible/test/play-rke/molecule/helm3/playbook.yml +++ /dev/null @@ -1 +0,0 @@ -../default/playbook.yml \ No newline at end of file -- cgit 1.2.3-korg