Debian Codegraph @

ansible_collections/google/cloud/tests/integration/targets/gcp_compute_instance/tasks/main.yml

raw
1 ---
2 - name: Generated tests
3 ansible.builtin.include_tasks: autogen.yml
4
5 - name: Extra non-autogen tests
6 block:
7 - name: Create network
8 google.cloud.gcp_compute_network:
9 name: "{{ resource_prefix }}"
10 project: "{{ gcp_project }}"
11 auth_kind: "{{ gcp_cred_kind }}"
12 service_account_file: "{{ gcp_cred_file | default(omit) }}"
13 auto_create_subnetworks: true
14 state: present
15 register: _network
16
17 - name: Test GVNIC test cases
18 ansible.builtin.include_tasks: gvnic.yml
19 loop: "{{ testcases | dict2items }}"
20 vars:
21 gcp_disk_image: projects/centos-cloud/global/images/family/centos-stream-9
22 gcp_zone: us-central1-a
23 testcases:
24 gvnic: GVNIC
25 virtio: VIRTIO_NET
26 default: default
27
28 - name: Test attach disks
29 ansible.builtin.include_tasks: attach-disks.yml
30 vars:
31 gcp_disk_image: projects/centos-cloud/global/images/family/centos-stream-9
32 gcp_zone: us-central1-a
33
34 - name: Test tags
35 ansible.builtin.include_tasks: tags.yml
36 vars:
37 gcp_disk_image: projects/centos-cloud/global/images/family/centos-stream-9
38 gcp_zone: us-central1-a
39
40 always:
41 - name: Delete network
42 google.cloud.gcp_compute_network:
43 name: "{{ resource_prefix }}"
44 project: "{{ gcp_project }}"
45 auth_kind: "{{ gcp_cred_kind }}"
46 service_account_file: "{{ gcp_cred_file | default(omit) }}"
47 auto_create_subnetworks: true
48 state: absent