Authentication for Google provider
Download the .json
authentication file and set the following terraform variable:
variable "credentials" {
description = "Service account credentials in json format"
default = "./keys/gcp_creds.json"
}
gcp_creds.json
{
"type": "service_account",
"project_id": "",
"private_key_id": "",
"private_key": "",
"client_email": "",
"client_id": "",
"auth_uri": "",
"token_uri": "",
"auth_provider_x509_cert_url": "",
"client_x509_cert_url": ""
}
For Terraform Cloud you have to configure the .json
as GOOGLE_CREDENTIALS
environment variable (all in one line).
Terraform google provider