Skip to content

Commit 57dd1c2

Browse files
Materialize LB ingress blocklist path before openstack_test include_role
role_path in include_role vars is evaluated in the included role, which broke ingress blocklist lookup under openstack_test/files. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 344d725 commit 57dd1c2

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

  • collection/stages/roles/lb_tests/tasks

‎collection/stages/roles/lb_tests/tasks/main.yml‎

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
- name: Best-effort cleanup of stale LB / e2e resources before Amphora tests
33
ansible.builtin.include_tasks: cleanup_lb_test_leftovers.yml
44

5+
# include_role(openstack_test) re-templates vars; role_path there is openstack_test, not lb_tests.
6+
- name: Materialize ingress blocklist path for nested openstack_test role
7+
ansible.builtin.set_fact:
8+
lb_ingress_blocklist_resolved: "{{ lb_blocklist_file }}"
9+
510
- name: Get install-config content to obtain the 1st machineCIDR
611
ansible.builtin.include_role:
712
name: shiftstack.tools.tools_get_deploy_info
@@ -33,7 +38,7 @@
3338
vars:
3439
openstack_test_results_dir: "{{ artifacts_dir }}/lb_amphora_sourceip"
3540
openstack_tests_allowlist_file: "{{ lb_allowlist_file }}"
36-
openstack_tests_blocklist_file: "{{ role_path }}/files/openstack-test-lb-ingress-blocklist.yaml"
41+
openstack_tests_blocklist_file: "{{ lb_ingress_blocklist_resolved }}"
3742
openstack_testsuite_name: openstack_tests_lb_amphora_sourceip
3843
openstack_reset_result_dir: no # As we want to keep the logs generated in the previous step
3944

@@ -52,6 +57,6 @@
5257
vars:
5358
openstack_test_results_dir: "{{ artifacts_dir }}/lb_ovn"
5459
openstack_tests_allowlist_file: "{{ lb_allowlist_file }}"
55-
openstack_tests_blocklist_file: "{{ role_path }}/files/openstack-test-lb-ingress-blocklist.yaml"
60+
openstack_tests_blocklist_file: "{{ lb_ingress_blocklist_resolved }}"
5661
openstack_testsuite_name: openstack_tests_lb_ovn
5762
openstack_reset_result_dir: no # As we want to keep the logs generated in the previous step

0 commit comments

Comments
 (0)