Skip to content

Commit

Permalink
Fixed validate-architecture zuul job
Browse files Browse the repository at this point in the history
* Fixed file name generation typo in `validate-architecture` playbook
* Added the ability of overriding
  `cifmw_networking_mapper_networking_env_def_path` job

Signed-off-by: Roberto Alfieri <[email protected]>
  • Loading branch information
rebtoor committed Jun 6, 2024
1 parent 327f2db commit 8d1092a
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 9 deletions.
4 changes: 2 additions & 2 deletions ci/playbooks/architecture/validate-architecture.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,13 @@
- name: Copy file on localhost
delegate_to: localhost
ansible.builtin.copy:
dest: "{{ lookup('env', 'HOME') }}/{{ cifmw_architecture_scenario }}.yml }}"
dest: "{{ lookup('env', 'HOME') ~ '/' ~ cifmw_architecture_scenario ~ '.yml' }}"
mode: "0644"
content: "{{ _mock_content.content | b64decode }}"

- name: Include var file
ansible.builtin.include_vars:
file: "{{ lookup('env', 'HOME') }}/{{ cifmw_architecture_scenario }}.yml }}"
file: "{{ lookup('env', 'HOME') ~ '/' ~ cifmw_architecture_scenario ~ '.yml' }}"

- name: Ensure kustomize_deploy is bootstraped
ansible.builtin.import_role:
Expand Down
20 changes: 13 additions & 7 deletions zuul.d/architecture-jobs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,25 @@
name: cifmw-architecture-validate-base
parent: cifmw-base-minimal
vars:
cifmw_networking_mapper_networking_env_def_path: >-
{{
[ansible_user_dir,
zuul.projects['github.com/openstack-k8s-operators/ci-framework'].src_dir,
'ci/playbooks/files/networking-env-definition.yml']
| path_join
}}
cifmw_architecture_repo: >-
{{
[ansible_user_dir,
zuul.projects['github.com/openstack-k8s-operators/architecture'].src_dir]
| path_join
}}
cifmw_networking_env_def_file_local: >-
{{
"" if not cifmw_networking_env_def_file else
([ cifmw_architecture_repo,
cifmw_networking_env_dev_file ] | path_join)
}}
cifmw_networking_mapper_networking_env_def_path: >-
{{
cifmw_networking_env_def_file_local |
default([ansible_user_dir,
zuul.projects['github.com/openstack-k8s-operators/ci-framework'].src_dir,
'ci/playbooks/files/networking-env-definition.yml'] | path_join, true)
}}
run:
- ci/playbooks/architecture/run.yml
required-projects:
Expand Down

0 comments on commit 8d1092a

Please sign in to comment.