File tree Expand file tree Collapse file tree
tools/cloud-build/daily-tests/ansible_playbooks Expand file tree Collapse file tree Original file line number Diff line number Diff line change 5757 ansible.builtin.include_tasks :
5858 file : tasks/create_deployment_directory.yml
5959
60+ - name : Set actual_network variable
61+ ansible.builtin.set_fact :
62+ actual_network : " {% if use_fixed_vpc | default(false) | bool %}{{ test_prefix | default('') }}{{ test_name }}-0{% else %}{{ network }}{% endif %}"
63+
6064 - name : Create Infrastructure and test
6165 block :
66+ - name : Clean up any existing PSA resources from previous runs
67+ ansible.builtin.include_tasks :
68+ file : tasks/cleanup_existing_psa.yml
69+ vars :
70+ psa_network : " {{ actual_network }}"
71+
6272 - name : Create Cluster with gcluster
6373 register : deployment
6474 changed_when : deployment.changed
120130 - " {{ deployment_name }}"
121131 - --direction=INGRESS
122132 - --priority=1000
123- - --network={% if use_fixed_vpc | default(false) %}{{ test_prefix | default('') }}{{ test_name }}-0{% else %}{{ network }}{% endif % }
133+ - --network={{ actual_network } }
124134 - --action=ALLOW
125135 - --rules=tcp:22
126136 - --source-ranges={{ build_ip.stdout }}
143153 ansible.builtin.add_host :
144154 hostname : " {{ remote_ip }}"
145155 groups : [remote_host]
156+ actual_network : " {{ actual_network }}"
146157 when : (remote_ip | default('')) | ansible.utils.ipaddr != false
147158
148159 - name : Wait for host tasks
Original file line number Diff line number Diff line change 5454
5555 - name : Set actual network name
5656 ansible.builtin.set_fact :
57- actual_network : " {% if use_fixed_vpc | default(false) %}{{ test_prefix | default('') }}{{ test_name }}-0{% else %}{{ network }}{% endif %}"
57+ actual_network : " {% if use_fixed_vpc | default(false) | bool %}{{ test_prefix | default('') }}{{ test_name }}-0{% else %}{{ network }}{% endif %}"
5858
5959 - name : Run Pre Deploy Tasks
6060 ansible.builtin.include_tasks : " {{ pre_deploy_task }}"
You can’t perform that action at this time.
0 commit comments