mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Bug fixes for gcp_storage_bucket (#42835)
This commit is contained in:
parent
528f81a8d5
commit
87c6d4be57
2 changed files with 427 additions and 269 deletions
File diff suppressed because it is too large
Load diff
|
@ -15,22 +15,18 @@
|
|||
# Pre-test setup
|
||||
- name: delete a bucket
|
||||
gcp_storage_bucket:
|
||||
name: 'ansible-storage-module'
|
||||
name: ansible-storage-module
|
||||
project: "{{ gcp_project }}"
|
||||
auth_kind: "{{ gcp_cred_kind }}"
|
||||
service_account_file: "{{ gcp_cred_file }}"
|
||||
scopes:
|
||||
- https://www.googleapis.com/auth/devstorage.full_control
|
||||
state: absent
|
||||
#----------------------------------------------------------
|
||||
- name: create a bucket
|
||||
gcp_storage_bucket:
|
||||
name: 'ansible-storage-module'
|
||||
name: ansible-storage-module
|
||||
project: "{{ gcp_project }}"
|
||||
auth_kind: "{{ gcp_cred_kind }}"
|
||||
service_account_file: "{{ gcp_cred_file }}"
|
||||
scopes:
|
||||
- https://www.googleapis.com/auth/devstorage.full_control
|
||||
state: present
|
||||
register: result
|
||||
- name: assert changed is true
|
||||
|
@ -41,12 +37,10 @@
|
|||
# ----------------------------------------------------------------------------
|
||||
- name: create a bucket that already exists
|
||||
gcp_storage_bucket:
|
||||
name: 'ansible-storage-module'
|
||||
name: ansible-storage-module
|
||||
project: "{{ gcp_project }}"
|
||||
auth_kind: "{{ gcp_cred_kind }}"
|
||||
service_account_file: "{{ gcp_cred_file }}"
|
||||
scopes:
|
||||
- https://www.googleapis.com/auth/devstorage.full_control
|
||||
state: present
|
||||
register: result
|
||||
- name: assert changed is false
|
||||
|
@ -57,12 +51,10 @@
|
|||
#----------------------------------------------------------
|
||||
- name: delete a bucket
|
||||
gcp_storage_bucket:
|
||||
name: 'ansible-storage-module'
|
||||
name: ansible-storage-module
|
||||
project: "{{ gcp_project }}"
|
||||
auth_kind: "{{ gcp_cred_kind }}"
|
||||
service_account_file: "{{ gcp_cred_file }}"
|
||||
scopes:
|
||||
- https://www.googleapis.com/auth/devstorage.full_control
|
||||
state: absent
|
||||
register: result
|
||||
- name: assert changed is true
|
||||
|
@ -73,12 +65,10 @@
|
|||
# ----------------------------------------------------------------------------
|
||||
- name: delete a bucket that does not exist
|
||||
gcp_storage_bucket:
|
||||
name: 'ansible-storage-module'
|
||||
name: ansible-storage-module
|
||||
project: "{{ gcp_project }}"
|
||||
auth_kind: "{{ gcp_cred_kind }}"
|
||||
service_account_file: "{{ gcp_cred_file }}"
|
||||
scopes:
|
||||
- https://www.googleapis.com/auth/devstorage.full_control
|
||||
state: absent
|
||||
register: result
|
||||
- name: assert changed is false
|
||||
|
|
Loading…
Reference in a new issue