Configuration of provider 0.87.2 not working on Gitlab #2661
-
Hi, I am using version 0.87.2 of the provider. Code is managed with Gitlab. Pipeline fails with the following error and I don't understand why. Error: No value for required variable Same error for the following variables: oauth_redirect_url, oauth_refresh_token, oauth_client_id, oauth_endpoint Here are my main.tf file and variables.tf main.tf: terraform { provider "snowflake" { variables.tf: variable "oauth_client_secret" { variable "oauth_redirect_url" { variable "oauth_refresh_token" { variable "oauth_client_id" { variable "oauth_endpoint" { Those variables have been defined on Gitlab as environment variables. For the name of those environment variables, we tried two things e.g. for oauth_client_id, we tried SNOWFLAKE_OAUTH_CLIENT_ID as mentioned in the documentation and we tried also with TF_VAR_OAUTH_CLIENT_ID. Same error. Any help will be greatly appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
Hey @olivierdewit. If Specifying the values for tf vars is not a Snowflake provider-specific question. Please consult terraform docs: https://developer.hashicorp.com/terraform/language/values/variables#environment-variables. |
Beta Was this translation helpful? Give feedback.
The deprecation warnings come from the fact that these parameters were deprecated in the provider's configuration. The new token_accessor was introduced. We will work on the configuration in the upcoming provider configuration rework https://github.com/Snowflake-Labs/terraform-provider-snowflake/blob/main/ROADMAP.md#providers-configuration-rework. For now try switching to token_accessor or ignore the warnings (remember that these are warnings, not errors).
The error
390303 (08004): Invalid OAuth access token.
is the error coming from Snowflake, so please reach out to Snowflake's support. The only thing I could find was https://community.snowflake.com/s/article/Error-Invalid-OAuth-access-t…