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

Can't create a postgres data source #2

Open
chelomontilla opened this issue Apr 19, 2022 · 0 comments
Open

Can't create a postgres data source #2

chelomontilla opened this issue Apr 19, 2022 · 0 comments

Comments

@chelomontilla
Copy link

Hello,
I'm trying to create a new datasource of type "pg" (Postgres) but I always get the following error:

│ Error: 400 from POST request to https://localhost:8080/api/data_sources: {"message": "The browser (or proxy) sent a request that this server could not understand."}
│ 
│   with module.redash_config.redash_data_source.test,
│   on ../../modules/redash_config/datasources.tf line 2, in resource "redash_data_source" "test":
│    2: resource "redash_data_source" "test" {
│ 
╵

The configuration for the datasource is:

resource "redash_data_source" "test" {
  name = "test"
  type = "pg"

  options {
    host     = "test.com"
    port     = 5432
    dbname   = "test"
    user     = "u_redash"
    password = "123456"
  }
}

If I try to send same configuration to the api directly it works:

{
    "name": "test",
    "type": "pg",
    "options": {
        "dbname": "test",
        "host": "test.com",
        "user": "u_redash",
        "password": "123456",
        "port": 5432
    }
}

I'm not sure what is the problem. Is there anyway to test and see what request the provider is sending to the API? I'm happy to help with the provider :)
The redash version I'm using is v10.1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant