When trying to use this Terraform plugin I cannot actually seem to communicate with Supabase. I get an error from the Go runtime like this whenever I try to apply:
Unable to create project, got error: Post "https://api.supabase.com/v1/projects": net/http: invalid header field value for "Authorization"
I have verified that my providers are correct (including my Supabase token in a resolvable file with no extra spaces/newlines) and terraform plan is showing everything is good to go.
Expected behavior
I should be able to run terraform apply and have my project resource be created.
Screenshots
Here is the relevant portion of the output from terraform apply:
Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# supabase_project.demo_base will be created
+ resource "supabase_project" "my_app" {
+ database_password = (sensitive value)
+ id = (known after apply)
+ name = "my_app"
+ organization_id = "vcblfrlrbmhqgtguaxhj"
+ region = "us-east-2"
}
Plan: 1 to add, 0 to change, 0 to destroy.
Do you want to perform these actions?
Terraform will perform the actions described above.
Only 'yes' will be accepted to approve.
Enter a value: yes
supabase_project.demo_base: Creating...
╷
│ Error: Client Error
│
│ with supabase_project.demo_base,
│ on main.tf line 1, in resource "supabase_project" "demo_base":
│ 1: resource "supabase_project" "demo_base" {
│
│ Unable to create project, got error: Post "https://api.supabase.com/v1/projects": net/http: invalid header field value for "Authorization"
System information
OS: macOS on arm64
Installed Terraform via brew and used terraform init to pull in the provider according to the tutorial
Additional context
I've fiddled with regenerating tokens and gone hunting for other solutions online. Any help is greatly appreciated.
Describe the bug
When trying to use this Terraform plugin I cannot actually seem to communicate with Supabase. I get an error from the Go runtime like this whenever I try to
apply
:To Reproduce
I followed the official guide: https://supabase.com/docs/guides/platform/terraform/tutorial
I have verified that my providers are correct (including my Supabase token in a resolvable file with no extra spaces/newlines) and
terraform plan
is showing everything is good to go.Expected behavior
I should be able to run
terraform apply
and have my project resource be created.Screenshots
Here is the relevant portion of the output from
terraform apply
:System information
brew
and usedterraform init
to pull in the provider according to the tutorialAdditional context
I've fiddled with regenerating tokens and gone hunting for other solutions online. Any help is greatly appreciated.