Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GCS backend credentials should allow content and not just path #18955

Closed
alwaysastudent opened this issue Sep 27, 2018 · 1 comment · Fixed by #26700
Closed

GCS backend credentials should allow content and not just path #18955

alwaysastudent opened this issue Sep 27, 2018 · 1 comment · Fixed by #26700

Comments

@alwaysastudent
Copy link

alwaysastudent commented Sep 27, 2018

Currently the GCS backed expects a relative path. But it would be desirable if we can pass the contents of the credentials JSON key as an argument over -backend-config= or we can interpolate a unique environment variable on the credentials attribute or retrofit another credentials attribute. Wish we can interpolate arbitrary environment variables.

Something like

data "terraform_remote_state" "remote1" {
  backend = "gcs"

  config {
    bucket      = "${bucket}"
    credentials = "$env(REMOTE1_CREDS)"
  }
}

data "terraform_remote_state" "remote2" {
  backend = "gcs"

  config {
    bucket      = "${bucket}"
    credentials = "$env(REMOTE2_CREDS)"
  }
}
@ghost
Copy link

ghost commented Dec 7, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked as resolved and limited conversation to collaborators Dec 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants