From da52c1136aa3e4ccf18eb3fb05acb3024a7f0e5d Mon Sep 17 00:00:00 2001 From: Jiri Podivin Date: Thu, 3 Feb 2022 08:54:18 +0100 Subject: [PATCH] Modifying catalogue execution test to resolve component pipeline issue Following validations were detecting changes in the image used by CI and reporting them as issues. While correct in case of a customer deployment, it is unnecessary within the component pipeline. The catalogue test will now no longer execute this validation. - image-serve Following validations will recieve variable overrides. - check-disk-space - check-disk-space-pre-upgrade - undercloud-disk-space-pre-upgrade - undercloud-disk-space Closes-Bug: #1959864 Signed-off-by: Jiri Podivin Change-Id: I24d04038b5add2a02577c94a5d7642e2e620088a (cherry picked from commit d7821d134744119076399b2cf8dd632f6c25f010) --- roles/validations/defaults/main.yaml | 1 + roles/validations/files/catalog_vars_override.yaml | 11 +++++++++++ roles/validations/tasks/execute_full_catalogue.yaml | 1 + roles/validations/tasks/main.yaml | 9 +++++++++ roles/validations/vars/main.yaml | 5 +++-- 5 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 roles/validations/files/catalog_vars_override.yaml diff --git a/roles/validations/defaults/main.yaml b/roles/validations/defaults/main.yaml index 3440a1d..d9cb82f 100644 --- a/roles/validations/defaults/main.yaml +++ b/roles/validations/defaults/main.yaml @@ -17,3 +17,4 @@ validation_component: "{{ job.component|default('validation') }}" cli_command: "validation" run_validation: true execute_full_vf_catalogue: "{{ job.execute_full_vf_catalogue|default(false)|bool }}" +vf_catalogue_overrides: "{{ ansible_user_dir }}/catalog_vars_override.yaml" diff --git a/roles/validations/files/catalog_vars_override.yaml b/roles/validations/files/catalog_vars_override.yaml new file mode 100644 index 0000000..f8b9a1c --- /dev/null +++ b/roles/validations/files/catalog_vars_override.yaml @@ -0,0 +1,11 @@ +--- +# LP#1959864 +volumes: + - {mount: /var/lib/docker, min_size: 10} + - {mount: /var/lib/config-data, min_size: 3} + - {mount: /var/log, min_size: 3} + - {mount: /usr, min_size: 5} + - {mount: /var, min_size: 8} + - {mount: /, min_size: 8} + +minimal_ram_gb: 2 diff --git a/roles/validations/tasks/execute_full_catalogue.yaml b/roles/validations/tasks/execute_full_catalogue.yaml index e8fc6e0..c24ff5b 100644 --- a/roles/validations/tasks/execute_full_catalogue.yaml +++ b/roles/validations/tasks/execute_full_catalogue.yaml @@ -12,4 +12,5 @@ --output-log validation_catalogue_execution.log {{ validation_catalogue.extra_args }} {{ validation_catalogue.extra_env_args }} + --extra-vars-file={{ vf_catalogue_overrides }} executable: /bin/bash diff --git a/roles/validations/tasks/main.yaml b/roles/validations/tasks/main.yaml index 9febee5..d968d3c 100644 --- a/roles/validations/tasks/main.yaml +++ b/roles/validations/tasks/main.yaml @@ -115,6 +115,15 @@ - validation_component | length > 0 with_dict: "{{ validations_list[validation_component] }}" +- name: Import variable overrides + become: true + copy: + src: files/catalog_vars_override.yaml + dest: "{{ vf_catalogue_overrides }}" + mode: "0644" + owner: "{{ ansible_user }}" + group: "{{ ansible_user }}" + - name: Execute entire validations catalogue include_tasks: execute_full_catalogue.yaml when: execute_full_vf_catalogue diff --git a/roles/validations/vars/main.yaml b/roles/validations/vars/main.yaml index bd787cf..b51f019 100644 --- a/roles/validations/vars/main.yaml +++ b/roles/validations/vars/main.yaml @@ -65,7 +65,7 @@ validation_list_formats: # extra_env_args and extra_args are shared for the execution # Included validations will be sorted alphabetically. validation_catalogue: - extra_args: "--extra-vars minimal_ram_gb=2" + extra_args: "" extra_env_args: "{{ extra_env_vars | default('') }}" full_list: - 512e @@ -86,7 +86,6 @@ validation_catalogue: - dhcp-provisioning - dns - healthcheck-service-status - - image-serve - mysql-open-files-limit - neutron-sanity-check - no-op @@ -149,3 +148,5 @@ validation_catalogue: # - tls-everywhere-prep # - undercloud-debug # - undercloud-service-status +# LP#1959864 +# - image-serve