Open xaurx opened 5 months ago
@wyatterp365 seems you forgot/lost comment you wanted to type.
I see the same behavior with the 5.45.0 provider. I was setting the GITHUB_TOKEN
env var, AND an env var github_pat_token
that was used to set the token into the provider block via TF_VAR_github_pat_token
provider "github" {
owner = "XXXXXX"
read_delay_ms = 500
token = var.github_pat_token
}
What's weird is this worked with the same setup last week. Others in my team are currently able to use it. I spent 2 days figuring out that I need to comment out the token
value:
provider "github" {
owner = "XXXXX"
read_delay_ms = 500
# token = var.github_pat_token
}
with ONLY the GITHUB_TOKEN
env var set, it works.
Expected Behavior
I initialize github provider v6.2.1 (latest at the moment) as following:
and it doesn't work, yet when I supply the same owner/token in env vars GITHUB_OWNER/GITHUB_TOKEN - it works.
I tried to debug using TF_LOG_PROVIDER=info, the only interesting messages:
and soon:
this seems related to the fact that no token provided.
since i want to keep token encrypted in TF files I need a way to pass it to provider not using env vars. please advise.
Actual Behavior
token/owner specified directly in provider are not used. (I verified that I don't have env vars set to any values at all)
Terraform Version
Terraform v1.5.7 on darwin_arm64
Affected Resource(s)
all
Terraform Configuration Files
Steps to Reproduce
just terraform apply:
Debug Output
No response
Panic Output
No response
Code of Conduct