NIFCLOUD security group rule has no description

Record why the rule permits the traffic.

Description

Use a security group rule’s description to explain which clients need the service and why the connection is allowed.

Potential impact

Ports and addresses alone may leave a reviewer unsure whether the rule is still needed.

Remediation

Use up to 40 characters. Terraform replaces this rule when its description changes, so review the plan and test the required connection after applying.

Examples

The web rule documents internal HTTP access. Its source (10.0.0.0/16) and TCP port (80) stay the same.

Before

hcl
resource "nifcloud_security_group_rule" "http" {
  security_group_names = ["web"]
  type                 = "IN"
  from_port            = 80
  to_port              = 80
  protocol             = "TCP"
  cidr_ip              = "10.0.0.0/16"
}

After

hcl
resource "nifcloud_security_group_rule" "http" {
  security_group_names = ["web"]
  type                 = "IN"
  description          = "HTTP for internal web clients"
  from_port            = 80
  to_port              = 80
  protocol             = "TCP"
  cidr_ip              = "10.0.0.0/16"
}

References