Disallow using invalid protocol.
resource "aws_security_group" "sample" {
description = "test security group"
ingress {
from_port = 443
to_port = 443
protocol = "https"
}
}
$ tflint
1 issue(s) found:
Error: "https" is an invalid protocol. It allows "tcp", "udp" or "-1"(all). (aws_security_group_invalid_protocol)
on terraform.tf line 7:
7: protocol = "https"
Apply will fail. (Plan will succeed with the invalid value though)
Select valid protocol according to the document