mirror of
https://github.com/ansible-collections/google.cloud.git
synced 2025-04-06 10:50:28 -07:00
Fix GCP Snapshot module when using own Encryption key
This commit is contained in:
parent
ec093086ab
commit
ed8fd22123
1 changed files with 8 additions and 0 deletions
|
@ -456,6 +456,10 @@ def resource_to_request(module):
|
||||||
u'name': module.params.get('name'),
|
u'name': module.params.get('name'),
|
||||||
u'description': module.params.get('description'),
|
u'description': module.params.get('description'),
|
||||||
u'storageLocations': module.params.get('storage_locations'),
|
u'storageLocations': module.params.get('storage_locations'),
|
||||||
|
u'sourceDiskEncryptionKey': SnapshotSourcediskencryptionkey(module.params.get('source_disk_encryption_key', {}),
|
||||||
|
module).to_request(),
|
||||||
|
u'snapshotEncryptionKey': SnapshotSnapshotencryptionkey(module.params.get('snapshot_encryption_key', {}),
|
||||||
|
module).to_request(),
|
||||||
u'labels': module.params.get('labels'),
|
u'labels': module.params.get('labels'),
|
||||||
}
|
}
|
||||||
return_vals = {}
|
return_vals = {}
|
||||||
|
@ -534,6 +538,10 @@ def response_to_hash(module, response):
|
||||||
u'description': module.params.get('description'),
|
u'description': module.params.get('description'),
|
||||||
u'storageBytes': response.get(u'storageBytes'),
|
u'storageBytes': response.get(u'storageBytes'),
|
||||||
u'storageLocations': response.get(u'storageLocations'),
|
u'storageLocations': response.get(u'storageLocations'),
|
||||||
|
u'sourceDiskEncryptionKey': SnapshotSourcediskencryptionkey(module.params.get('source_disk_encryption_key', {}),
|
||||||
|
module).from_response(),
|
||||||
|
u'snapshotEncryptionKey': SnapshotSnapshotencryptionkey(module.params.get('snapshot_encryption_key', {}),
|
||||||
|
module).from_response(),
|
||||||
u'licenses': response.get(u'licenses'),
|
u'licenses': response.get(u'licenses'),
|
||||||
u'labels': response.get(u'labels'),
|
u'labels': response.get(u'labels'),
|
||||||
u'labelFingerprint': response.get(u'labelFingerprint'),
|
u'labelFingerprint': response.get(u'labelFingerprint'),
|
||||||
|
|
Loading…
Add table
Reference in a new issue