Difference between revisions of "Terraform PostgreSQL Provider"
Jump to navigation
Jump to search
(9 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
+ | * [[cyrilgdn]]: https://registry.terraform.io/providers/cyrilgdn/postgresql/latest/docs | ||
+ | https://github.com/hashicorp/terraform/issues/30559#issuecomment-1045141735 | ||
+ | terraform { | ||
+ | required_version = ">= 1.1.6" | ||
+ | required_providers { | ||
+ | postgresql = { # This line is what needs to change. | ||
+ | source = "[[cyrilgdn]]/postgresql" | ||
+ | } | ||
+ | } | ||
+ | } | ||
+ | |||
+ | provider "postgresql" { | ||
+ | host = "test" | ||
+ | port = 5432 | ||
+ | database = "test" | ||
+ | username = "test" | ||
+ | password = "test" | ||
+ | sslmode = "require" | ||
+ | connect_timeout = 15 | ||
+ | } | ||
+ | == Errors == | ||
+ | [[terraform init]] | ||
+ | |||
+ | Initializing the backend... | ||
+ | |||
+ | Initializing provider plugins... | ||
+ | - Finding latest version of hashicorp/postgresql... | ||
+ | ╷ | ||
+ | │ Error: Failed to query available provider packages | ||
+ | │ | ||
+ | │ Could not retrieve the list of available versions for provider hashicorp/postgresql: provider registry registry.terraform.io does not have a | ||
+ | │ provider named registry.terraform.io/hashicorp/postgresql | ||
+ | │ | ||
+ | │ Did you intend to use [[cyrilgdn]]/postgresql? If so, you must specify that source address in each module which requires that provider. To see w hich | ||
+ | │ modules are currently depending on hashicorp/postgresql, run the following command: | ||
+ | │ terraform providers | ||
+ | ╵ | ||
+ | == Related == | ||
* [[Terraform MySQL Provider]] | * [[Terraform MySQL Provider]] | ||
− | + | * [[Error: Invalid provider local name]] | |
== See also == | == See also == | ||
− | * {{tf | + | * {{tf init}} |
+ | * {{tf pg}} | ||
[[Category:TF]] | [[Category:TF]] |
Latest revision as of 18:07, 8 January 2024
https://github.com/hashicorp/terraform/issues/30559#issuecomment-1045141735
terraform { required_version = ">= 1.1.6" required_providers { postgresql = { # This line is what needs to change. source = "cyrilgdn/postgresql" } } } provider "postgresql" { host = "test" port = 5432 database = "test" username = "test" password = "test" sslmode = "require" connect_timeout = 15 }
Errors[edit]
terraform init Initializing the backend... Initializing provider plugins... - Finding latest version of hashicorp/postgresql... ╷ │ Error: Failed to query available provider packages │ │ Could not retrieve the list of available versions for provider hashicorp/postgresql: provider registry registry.terraform.io does not have a │ provider named registry.terraform.io/hashicorp/postgresql │ │ Did you intend to use cyrilgdn/postgresql? If so, you must specify that source address in each module which requires that provider. To see w hich │ modules are currently depending on hashicorp/postgresql, run the following command: │ terraform providers ╵
Related[edit]
See also[edit]
Advertising: