Integration test for new IAP connection plugin

1. creates instances with a custom ssh keypair
2. change the connection plugin method and perform basic checks
3. cleanup
This commit is contained in:
Jorge Gallegos 2025-09-04 19:28:23 -07:00
commit 5745bdaac2
No known key found for this signature in database
8 changed files with 215 additions and 0 deletions

View file

@ -0,0 +1,31 @@
---
plugin: google.cloud.gcp_compute
zones:
{{ gcp_zones | to_nice_yaml }}
projects:
- {{ gcp_project }}
auth_kind: {{ gcp_cred_kind }}
service_account_file: {{ gcp_cred_file }}
scopes:
- 'https://www.googleapis.com/auth/cloud-platform'
- 'https://www.googleapis.com/auth/compute.readonly'
keyed_groups:
- prefix: gcp
key: labels
filters:
- 'labels.test:{{ prefix }}'
hostnames:
- name
# set variables for the connection plugin
compose:
ansible_gcloud_zone: zone
ansible_gcloud_project: project