Closed magsoftware closed 4 years ago
@magsoftware apologies you hit this.
Was this a one time failure or is it failing every time you run it?
Could you please provide a full reproducible config that I can copy paste? i.e. with values instead of vars.
@eddiezane thank you for quick reply.
Was this a one time failure or is it failing every time you run it?
I get it every time I run the script.
Could you please provide a full reproducible config that I can copy paste? i.e. with values instead of vars.
All files are attached below.
Just a note:
same result:
digitalocean_database_cluster.rdb-cluster: Still creating... [4m50s elapsed]
digitalocean_database_cluster.rdb-cluster: Still creating... [5m0s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [5m0s elapsed]
digitalocean_database_cluster.rdb-cluster: Creation complete after 5m3s [id=8122b7d9-750b-4ea5-b160-ca403da7ecce]
digitalocean_database_user.rdb-user: Creating...
digitalocean_database_db.rdb-database: Creating...
digitalocean_database_connection_pool.rdb-connection-pool: Creating...
digitalocean_project.flexvoucher: Creating...
digitalocean_database_db.rdb-database: Creation complete after 2s [id=8122b7d9-750b-4ea5-b160-ca403da7ecce/database/fv]
digitalocean_database_user.rdb-user: Creation complete after 2s [id=8122b7d9-750b-4ea5-b160-ca403da7ecce/user/fv]
digitalocean_project.flexvoucher: Creation complete after 3s [id=4e453610-655e-4851-9dfe-f358510ea8c7]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [5m10s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [5m20s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [5m30s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [5m40s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [5m50s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [6m0s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [6m10s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [6m20s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [6m30s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [6m40s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Still creating... [6m50s elapsed]
digitalocean_kubernetes_cluster.flexvoucher: Creation complete after 6m53s [id=35e3f4f8-bca6-401a-8a30-9e71f8384790]
digitalocean_database_firewall.rdb-firewall: Creating...
digitalocean_database_firewall.rdb-firewall: Creation complete after 3s [id=8122b7d9-750b-4ea5-b160-ca403da7ecce-20200220143233376700000001]
Error: Error creating DatabaseConnectionPool: POST https://api.digitalocean.com/v2/databases/8122b7d9-750b-4ea5-b160-ca403da7ecce/pools: 500 Server Error
on rdb.tf line 37, in resource "digitalocean_database_connection_pool" "rdb-connection-pool":
37: resource "digitalocean_database_connection_pool" "rdb-connection-pool" {
If I run terraform apply once again:
data.digitalocean_kubernetes_versions.k8s_versions: Refreshing state...
digitalocean_spaces_bucket.flexvoucher-assets: Refreshing state... [id=flexvoucher]
digitalocean_database_cluster.rdb-cluster: Refreshing state... [id=8122b7d9-750b-4ea5-b160-ca403da7ecce]
digitalocean_kubernetes_cluster.flexvoucher: Refreshing state... [id=35e3f4f8-bca6-401a-8a30-9e71f8384790]
digitalocean_database_db.rdb-database: Refreshing state... [id=8122b7d9-750b-4ea5-b160-ca403da7ecce/database/fv]
digitalocean_database_firewall.rdb-firewall: Refreshing state... [id=8122b7d9-750b-4ea5-b160-ca403da7ecce-20200220143233376700000001]
digitalocean_database_user.rdb-user: Refreshing state... [id=8122b7d9-750b-4ea5-b160-ca403da7ecce/user/fv]
digitalocean_project.flexvoucher: Refreshing state... [id=4e453610-655e-4851-9dfe-f358510ea8c7]
digitalocean_database_connection_pool.rdb-connection-pool: Creating...
digitalocean_database_connection_pool.rdb-connection-pool: Creation complete after 3s [id=8122b7d9-750b-4ea5-b160-ca403da7ecce/fv_pool]
All good. Looks like all resources are created as specified in tf files.
We are currently getting 500s when trying to create connection pools with names longer than 60 characters. The UI claims that the limit is between 3 and 63 characters, but creating one with >60 characters is failing.
I found a possible explanation for the above issue. The connection pool size can be a maximum of 25 *
We've added some validation around this and the DO API should now be returning a proper error message as well. I'm going to go ahead and close this one out. Please feel free to reopen if you experience this again or have additional details.
Terraform Version
Terraform v0.12.20
Affected Resource(s)
I create a managed database + k8s cluster. Database is ready first than the cluster. Than I want to create a firewall for database and allow traffic from k8s cluster.
Terraform Configuration Files
Debug Output
other
Panic Output
If Terraform produced a panic, please provide a link to a GitHub Gist containing the output of the
crash.log
.Expected Behavior
This should create a database firewall rule to allow traffic from k8s cluster.
Actual Behavior
API crashes.
Steps to Reproduce
terraform apply
terraform.logTF log attached.