diff --git a/group_vars/all.yml b/group_vars/all.yml index 3a84ffffbc..4add9afd8d 100644 --- a/group_vars/all.yml +++ b/group_vars/all.yml @@ -8,3 +8,4 @@ cifmw_project_dir_absolute: "{{ ansible_user_dir }}/{{ cifmw_project_dir }}" cifmw_installyamls_repos_relative: src/github.com/openstack-k8s-operators/install_yamls # since cifmw_installyamls_repos var already exists, let's use that and move all definition here in single place instead of creating another variable. cifmw_installyamls_repos: "{{ ansible_user_dir }}/{{ cifmw_installyamls_repos_relative }}" +cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data" diff --git a/hooks/playbooks/group_vars b/hooks/playbooks/group_vars new file mode 120000 index 0000000000..14bb1b3d9f --- /dev/null +++ b/hooks/playbooks/group_vars @@ -0,0 +1 @@ +../../group_vars \ No newline at end of file diff --git a/roles/reportportal/defaults/main.yml b/roles/reportportal/defaults/main.yml index acbf8f8b0f..68e1763014 100644 --- a/roles/reportportal/defaults/main.yml +++ b/roles/reportportal/defaults/main.yml @@ -1,6 +1,6 @@ --- cifmw_reportportal_dry_run: false -cifmw_reportportal_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}" +cifmw_reportportal_basedir: "{{ cifmw_basedir }}" cifmw_reportportal_datarouter_url: "" cifmw_reportportal_datarouter_username: "" cifmw_reportportal_datarouter_password: "" diff --git a/roles/reproducer/defaults/main.yml b/roles/reproducer/defaults/main.yml index ca312765df..cd5d0c19e7 100644 --- a/roles/reproducer/defaults/main.yml +++ b/roles/reproducer/defaults/main.yml @@ -20,7 +20,7 @@ cifmw_reproducer_controller_user: "{{ hostvars['controller-0']['ansible_ssh_user'] | default('zuul') }}" cifmw_reproducer_controller_user_dir: "/home/{{ cifmw_reproducer_controller_user }}" cifmw_reproducer_controller_basedir: "{{ cifmw_reproducer_controller_user_dir }}/ci-framework-data" -cifmw_reproducer_basedir: "{{ cifmw_basedir | default( ansible_user_dir ~ '/ci-framework-data') }}" +cifmw_reproducer_basedir: "{{ cifmw_basedir }}" cifmw_reproducer_src_dir: "{{ cifmw_ci_src_dir | default( ansible_user_dir ~ '/src') }}" cifmw_reproducer_kubecfg: "{{ cifmw_libvirt_manager_configuration.vms.crc.image_local_dir }}/kubeconfig" cifmw_reproducer_params: {} diff --git a/roles/rhol_crc/defaults/main.yml b/roles/rhol_crc/defaults/main.yml index 5bcfb9fc6f..3b062f660c 100644 --- a/roles/rhol_crc/defaults/main.yml +++ b/roles/rhol_crc/defaults/main.yml @@ -39,8 +39,7 @@ cifmw_rhol_crc_base_url: >- # In case we don't use cifmw_basedir it will get the # base_dir of the project if .git exists - change dir # does not affect other tasks: -cifmw_rhol_crc_basedir: >- - {{ cifmw_basedir | default( ansible_user_dir ~ '/ci-framework-data') }} +cifmw_rhol_crc_basedir: "{{ cifmw_basedir }}" cifmw_rhol_crc_binary_folder: "{{ ansible_user_dir }}/bin" cifmw_rhol_crc_binary: "{{ cifmw_rhol_crc_binary_folder }}/crc" cifmw_rhol_crc_force_cleanup: false diff --git a/roles/run_hook/tasks/playbook.yml b/roles/run_hook/tasks/playbook.yml index 5f6e79afd8..a9f33bf93c 100644 --- a/roles/run_hook/tasks/playbook.yml +++ b/roles/run_hook/tasks/playbook.yml @@ -12,8 +12,7 @@ {%- else -%} {{ hook.source }} {%- endif -%} - _bdir: >- - {{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }} + _bdir: "{{ cifmw_basedir }}" _operator_namespace: >- {{ cifmw_install_yamls_defaults['OPERATOR_NAMESPACE'] | diff --git a/roles/set_openstack_containers/defaults/main.yml b/roles/set_openstack_containers/defaults/main.yml index 22b88a6ac5..f2e2426301 100644 --- a/roles/set_openstack_containers/defaults/main.yml +++ b/roles/set_openstack_containers/defaults/main.yml @@ -17,7 +17,7 @@ # All variables intended for modification should be placed in this file. # All variables within this role should have a prefix of "cifmw_set_openstack_containers" -cifmw_set_openstack_containers_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}" +cifmw_set_openstack_containers_basedir: "{{ cifmw_basedir }}" cifmw_set_openstack_containers_registry: quay.io cifmw_set_openstack_containers_namespace: podified-antelope-centos9 cifmw_set_openstack_containers_tag: current-podified diff --git a/roles/shiftstack/defaults/main.yml b/roles/shiftstack/defaults/main.yml index 1fc9401d18..7136359fad 100644 --- a/roles/shiftstack/defaults/main.yml +++ b/roles/shiftstack/defaults/main.yml @@ -19,7 +19,7 @@ # All variables within this role should have a prefix of "cifmw_shiftstack" cifmw_shiftstack_ansible_command_logs_dir: "{{ cifmw_shiftstack_basedir }}/ansible_command_logs" cifmw_shiftstack_artifacts_dir: "{{ cifmw_shiftstack_basedir }}/artifacts" -cifmw_shiftstack_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}/tests/shiftstack" +cifmw_shiftstack_basedir: "{{ cifmw_basedir }}/tests/shiftstack" cifmw_shiftstack_client_incluster_secret_manifest: "{{ cifmw_shiftstack_client_pod_name }}_incluster_secret.yml" cifmw_shiftstack_client_incluster_secret_name: "incluster-kubeconfig" cifmw_shiftstack_client_pod_image: "quay.io/shiftstack-qe/shiftstack-client:latest" diff --git a/roles/sushy_emulator/defaults/main.yml b/roles/sushy_emulator/defaults/main.yml index 006fd15249..5942356a70 100644 --- a/roles/sushy_emulator/defaults/main.yml +++ b/roles/sushy_emulator/defaults/main.yml @@ -18,8 +18,7 @@ # All variables intended for modification should be placed in this file. # All variables within this role should have a prefix of "cifmw_sushy_emulator" -cifmw_sushy_emulator_basedir: >- - {{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }} +cifmw_sushy_emulator_basedir: "{{ cifmw_basedir }}" cifmw_sushy_emulator_container_name: "cifmw-sushy_emulator" cifmw_sushy_emulator_driver: libvirt cifmw_sushy_emulator_driver_openstack_client_config_file: /etc/openstack/clouds.yaml diff --git a/roles/tempest/defaults/main.yml b/roles/tempest/defaults/main.yml index 0c65635699..6b387409c9 100644 --- a/roles/tempest/defaults/main.yml +++ b/roles/tempest/defaults/main.yml @@ -17,7 +17,7 @@ # All variables intended for modification should be placed in this file. # All variables within this role should have a prefix of "cifmw_tempest" -cifmw_tempest_artifacts_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}/tests/tempest" +cifmw_tempest_artifacts_basedir: "{{ cifmw_basedir }}/tests/tempest" cifmw_tempest_default_groups: - default cifmw_tempest_default_jobs: diff --git a/roles/tempest/molecule/default/prepare.yml b/roles/tempest/molecule/default/prepare.yml index 810486ac1a..445d8f04dc 100644 --- a/roles/tempest/molecule/default/prepare.yml +++ b/roles/tempest/molecule/default/prepare.yml @@ -19,7 +19,6 @@ hosts: all vars: ansible_user_dir: "{{ lookup('env', 'HOME') }}" - cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data" cifmw_install_yamls_tasks_out: "{{ ansible_user_dir }}/zuul-jobs/roles/install_yamls_makes/tasks" cifmw_install_yamls_defaults: NAMESPACE: openstack diff --git a/roles/test_operator/defaults/main.yml b/roles/test_operator/defaults/main.yml index 2b664340ad..248fd3fce6 100644 --- a/roles/test_operator/defaults/main.yml +++ b/roles/test_operator/defaults/main.yml @@ -23,7 +23,7 @@ cifmw_test_operator_stages: - name: tempest type: tempest cifmw_test_operator_fail_on_test_failure: true -cifmw_test_operator_artifacts_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}/tests/test_operator" +cifmw_test_operator_artifacts_basedir: "{{ cifmw_basedir }}/tests/test_operator" cifmw_test_operator_namespace: openstack cifmw_test_operator_controller_namespace: openstack-operators cifmw_test_operator_bundle: "" @@ -42,7 +42,7 @@ cifmw_test_operator_storage_class: "{{ cifmw_test_operator_storage_class_prefix cifmw_test_operator_delete_logs_pod: false cifmw_test_operator_privileged: true cifmw_test_operator_selinux_level: "s0:c478,c978" -cifmw_test_operator_crs_path: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}/artifacts/test-operator-crs" +cifmw_test_operator_crs_path: "{{ cifmw_basedir }}/artifacts/test-operator-crs" cifmw_test_operator_log_pod_definition: apiVersion: v1 kind: Pod diff --git a/roles/update/tasks/update_variant_split.yml b/roles/update/tasks/update_variant_split.yml index 346408cfa0..d5242c8552 100644 --- a/roles/update/tasks/update_variant_split.yml +++ b/roles/update/tasks/update_variant_split.yml @@ -22,7 +22,7 @@ - name: Run tests after Services update vars: - cifmw_test_operator_artifacts_basedir: "{{ cifmw_basedir|default(ansible_user_dir ~ '/ci-framework-data') }}/tests/test_operator_update" + cifmw_test_operator_artifacts_basedir: "{{ cifmw_basedir }}/tests/test_operator_update" cifmw_test_operator_tempest_name: "post-services-update-tempest-tests" ansible.builtin.include_role: name: cifmw_setup diff --git a/roles/update_containers/defaults/main.yml b/roles/update_containers/defaults/main.yml index da7c0e65b6..5b4d8a2126 100644 --- a/roles/update_containers/defaults/main.yml +++ b/roles/update_containers/defaults/main.yml @@ -20,10 +20,7 @@ cifmw_update_containers: false cifmw_update_containers_namespace: openstack -cifmw_update_containers_base_dir: >- - {{ - cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') - }} +cifmw_update_containers_base_dir: "{{ cifmw_basedir }}" cifmw_update_containers_dest_path: >- {{ [ diff --git a/roles/validations/defaults/main.yml b/roles/validations/defaults/main.yml index fbc9d2cfdd..4570670a4e 100644 --- a/roles/validations/defaults/main.yml +++ b/roles/validations/defaults/main.yml @@ -40,7 +40,7 @@ cifmw_validations_default_path: "{{ role_path }}/tasks" cifmw_validations_edpm_check_node: compute-0 cifmw_validations_edpm_second_check_node: compute-1 -cifmw_validations_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}" +cifmw_validations_basedir: "{{ cifmw_basedir }}" cifmw_validations_namespace: "openstack" diff --git a/scenarios/centos-9/base.yml b/scenarios/centos-9/base.yml index f9cefb94d1..9492a0bcc0 100644 --- a/scenarios/centos-9/base.yml +++ b/scenarios/centos-9/base.yml @@ -2,4 +2,3 @@ # Configure base system to match centos cifmw_repo_setup_os_release: 'centos' cifmw_repo_setup_dist_major_version: 9 -cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data" diff --git a/scenarios/centos-9/kuttl.yml b/scenarios/centos-9/kuttl.yml index ea3ab7544c..cc75d6065e 100644 --- a/scenarios/centos-9/kuttl.yml +++ b/scenarios/centos-9/kuttl.yml @@ -1,6 +1,6 @@ --- cifmw_install_yamls_vars: BMO_SETUP: false -cifmw_artifacts_basedir: "{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}" +cifmw_artifacts_basedir: "{{ cifmw_basedir }}" cifmw_openshift_setup_skip_internal_registry: true diff --git a/scenarios/reproducers/3-nodes.yml b/scenarios/reproducers/3-nodes.yml index eb30c5243c..e4f9dea487 100644 --- a/scenarios/reproducers/3-nodes.yml +++ b/scenarios/reproducers/3-nodes.yml @@ -3,7 +3,6 @@ # We can't use ansible_user_dir here, unless you have the same user on the # hypervisor and locally. # This will be created on the hypervisor. -cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data" cifmw_path: "{{ ansible_user_dir }}/.crc/bin:{{ ansible_user_dir }}/.crc/bin/oc:{{ ansible_user_dir }}/bin:{{ ansible_env.PATH }}" cifmw_rhol_crc_config: diff --git a/scenarios/reproducers/va-common.yml b/scenarios/reproducers/va-common.yml index 5b92bcb41c..b5dfcc72fa 100644 --- a/scenarios/reproducers/va-common.yml +++ b/scenarios/reproducers/va-common.yml @@ -10,7 +10,6 @@ # Ensure some basic directories and parameter are set -cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data" cifmw_path: "{{ ansible_user_dir }}/bin:{{ ansible_env.PATH }}" # Ensure our vbmcd isn't conflicting with devscripts managed instance diff --git a/update-edpm.yml b/update-edpm.yml index c610262474..0019976255 100644 --- a/update-edpm.yml +++ b/update-edpm.yml @@ -26,7 +26,7 @@ tasks: - name: Run Test vars: - cifmw_test_operator_artifacts_basedir: "{{ cifmw_basedir|default(ansible_user_dir ~ '/ci-framework-data') }}/tests/test_operator_update" + cifmw_test_operator_artifacts_basedir: "{{ cifmw_basedir }}/tests/test_operator_update" cifmw_test_operator_tempest_name: "post-update-tempest-tests" ansible.builtin.import_role: name: cifmw_setup