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

PostgreSQL provider doesn't seem to support Azure AD users #10877

Closed
waynejnicklin opened this issue Mar 8, 2021 · 5 comments
Closed

PostgreSQL provider doesn't seem to support Azure AD users #10877

waynejnicklin opened this issue Mar 8, 2021 · 5 comments

Comments

@waynejnicklin
Copy link

I can successfully add an Azure AD user as PostgreSQL admin, but when I try and connect to the PostgreSQL server using the same user (to add SQL roles etc.), I get the following error:

Error: Error initializing PostgreSQL client: error detecting capabilities: error PostgreSQL version: pq: An error occurred while validating the access token. Please acquire a new token and retry

Do I have to do something different with the Terraform provider to use an Azure AD user? Here is my config:

provider "postgresql" {
host = var.sql_server
port = 5432
database = var.service_name
username = var.sql_username
password = var.sql_password
sslmode = "require"
superuser = false
connect_timeout = 15
}

Thanks,
Wayne

@jackofallops
Copy link
Member

Hi @waynejnicklin - this is the repository for the Azure RM provider. We don't support a postgres provider here, but if the provider you're using published on the registry, you can possibly reach that provider's developer through the project links there? https://registry.terraform.io/search/providers?q=postgres

Since this is a question on another provider I'm going to close this issue.

@waynejnicklin
Copy link
Author

The provider I'm assuming is the hashicorp one. If I try and create an issue there it says the archive is closed and read-only.

https://github.com/hashicorp/terraform-provider-postgresql

terraform {
required_providers {
postgresql = {
source = "terraform-providers/postgresql"
}
}
}

@jackofallops
Copy link
Member

Hi @waynejnicklin - That's an archived provider from a time when all providers were held in our GitHub Org. There's a note on that repo directing you to the owner and maintainer's Github project, they may be able to assist: https://registry.terraform.io/providers/cyrilgdn/postgresql / https://github.com/cyrilgdn/terraform-provider-postgresql

@waynejnicklin
Copy link
Author

Great thank you :-)

@ghost
Copy link

ghost commented Apr 7, 2021

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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!

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

No branches or pull requests

2 participants