paultyng / terraform-provider-unifi

Terraform provider for Unifi :satellite:
https://registry.terraform.io/providers/paultyng/unifi/latest/docs
Mozilla Public License 2.0
522 stars 91 forks source link

unifi_port_forward name is required #451

Open markti opened 8 months ago

markti commented 8 months ago

if you create a "unifi_port_forward" with the name absent you are able to apply the change but when you navigate to the UDMP management console it throws an error! should probably implement validation on required fields and avoid conflicts. For example I had an existing port forwarding setting for my Roon ARC server and I was able to create another one that conflicted with the same IP range. maybe conflicting IP ranges its possible but at least required fields should be validated.

resource "unifi_port_forward" "roon" {
  name                   = "Roon ARC"
  port_forward_interface = "wan"
  dst_port               = "45584"
  fwd_ip                 = "192.168.1.39"
  fwd_port               = "45584"
  log                    = true
}