From dfd01a67adcb52f984bc3a9755a312cc60fc5a82 Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Fri, 4 Aug 2023 15:40:30 +0200 Subject: digitalocean/firewall: open ports for UDP also --- digitalocean/firewall/main.tf | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'digitalocean') diff --git a/digitalocean/firewall/main.tf b/digitalocean/firewall/main.tf index 937a76a..b0a435a 100644 --- a/digitalocean/firewall/main.tf +++ b/digitalocean/firewall/main.tf @@ -21,6 +21,16 @@ resource "digitalocean_firewall" "this" { } } + dynamic "inbound_rule" { + for_each = var.open_ports + + content { + protocol = "udp" + port_range = inbound_rule.value + source_addresses = ["0.0.0.0/0", "::/0"] + } + } + outbound_rule { protocol = "tcp" port_range = "1-65535" -- cgit v1.2.3