thojkooi / terraform-digitalocean-docker-swarm-firewall

Terraform module to configure Docker Swarm mode firewall rules on DigitalOcean.
https://registry.terraform.io/modules/thojkooi/docker-swarm-firewall/digitalocean/
MIT License
9 stars 7 forks source link

Does not work with digitalocean provider version ~1.0.0 #8

Open cpxPratik opened 5 years ago

cpxPratik commented 5 years ago

With digitalocean provider version 1.0.2 or 1.1.0, module shows following error. While bumping down to 0.1.3, it works as usual. When reviewing changelog of provider, i cannot see anything that can break the behaviour.

Error: Error applying plan:

4 error(s) occurred:

* module.default-firewall.digitalocean_firewall.outbound-http: 1 error(s) occurred:

* digitalocean_firewall.outbound-http: Error creating firewall: POST https://api.digitalocean.com/v2/firewalls: 500 Server was unable to give you a response.
* module.docker-swarm-firewall.digitalocean_firewall.swarm-mode-internal-fw: 1 error(s) occurred:

* digitalocean_firewall.swarm-mode-internal-fw: Error creating firewall: POST https://api.digitalocean.com/v2/firewalls: 500 Server was unable to give you a response.
* module.default-firewall.digitalocean_firewall.outbound-dns: 1 error(s) occurred:

* digitalocean_firewall.outbound-dns: Error creating firewall: POST https://api.digitalocean.com/v2/firewalls: 500 Server was unable to give you a response.
* module.default-firewall.digitalocean_firewall.outbound-ntp: 1 error(s) occurred:

* digitalocean_firewall.outbound-ntp: Error creating firewall: POST https://api.digitalocean.com/v2/firewalls: 500 Server was unable to give you a response.
cpxPratik commented 5 years ago

Quickfix: If i declare resources from this module directly in my .tf files and add depends_on argument on firewall resources to explicitly depend on manager, worker droplets, firewalls are created and applied as usual.

Same fix for https://github.com/thojkooi/terraform-digitalocean-firewall-rules/issues/1