diff --git a/changelogs/fragments/gcp_fixes.yml b/changelogs/fragments/gcp_fixes.yml index 3cc57c98786..1cf0f3c972f 100644 --- a/changelogs/fragments/gcp_fixes.yml +++ b/changelogs/fragments/gcp_fixes.yml @@ -1,2 +1,2 @@ bugfixes: - - Add no_log to credentials field to avoid disclosures, also switch type to jsonarg to avoid having users responsible for transformations. + - Add no_log to credentials field to avoid disclosures diff --git a/lib/ansible/module_utils/gcp_utils.py b/lib/ansible/module_utils/gcp_utils.py index 48198d0752b..568495da858 100644 --- a/lib/ansible/module_utils/gcp_utils.py +++ b/lib/ansible/module_utils/gcp_utils.py @@ -205,8 +205,8 @@ class GcpModule(AnsibleModule): service_account_contents=dict( required=False, fallback=(env_fallback, ['GCP_SERVICE_ACCOUNT_CONTENTS']), - no_log=True, - type='jsonarg'), + type='str', + no_log=True), scopes=dict( required=False, fallback=(env_fallback, ['GCP_SCOPES']), diff --git a/lib/ansible/plugins/doc_fragments/gcp.py b/lib/ansible/plugins/doc_fragments/gcp.py index dab3febd620..fe3d14d4678 100644 --- a/lib/ansible/plugins/doc_fragments/gcp.py +++ b/lib/ansible/plugins/doc_fragments/gcp.py @@ -21,7 +21,7 @@ options: service_account_contents: description: - The contents of a Service Account JSON file, either in a dictionary or as a JSON string that represents it. - type: jsonarg + type: str service_account_file: description: - The path of a Service Account JSON file if serviceaccount is selected as type.