You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description of issue.
When using an SSM paramter store lookup to get a CIDR Range to use in a Security group, cfn-lint raised an E2004 error.
Parameters:
VpcID:
Description: ID of VPCType: "AWS::SSM::Parameter::Value<String>"Default: VpcIdAllowedValues:
- VpcIdVpcCidrRange:
Description: CIDR range of VPCType: "AWS::SSM::Parameter::Value<String>"Default: VpcCIDRRangeAllowedValues:
- VpcCIDRRangeResources:
SecurityGroup:
Type: AWS::EC2::SecurityGroupProperties:
GroupDescription: Allow HTTP egressVpcId: !Ref VpcIDSecurityGroupEgress:
- IpProtocol: tcpFromPort: 80ToPort: 80CidrIp: !Ref VpcCidrRange
Error is E2004 Cidr should be a Cidr Range based string for VpcCIDRRange product.template.yaml:9:3
If I'm not misunderstanding, cfn-lint seems to be complaining that the String VpcCIDRRange is not a valid CIDR, where in fact during runtime CloudFormation will lookup the value of VpcCIDRRange in SSM Parameter Store and use that instead.
I guess a sensible approach here would be to disable E2004 for parameters that have a type of AWS::SSM::Parameter::Value<String> maybe?
The text was updated successfully, but these errors were encountered:
cfn-lint version: (
cfn-lint --version
)0.33.0
Description of issue.
When using an SSM paramter store lookup to get a CIDR Range to use in a Security group, cfn-lint raised an E2004 error.
Error is
E2004 Cidr should be a Cidr Range based string for VpcCIDRRange product.template.yaml:9:3
If I'm not misunderstanding, cfn-lint seems to be complaining that the String
VpcCIDRRange
is not a valid CIDR, where in fact during runtime CloudFormation will lookup the value ofVpcCIDRRange
in SSM Parameter Store and use that instead.I guess a sensible approach here would be to disable E2004 for parameters that have a type of
AWS::SSM::Parameter::Value<String>
maybe?The text was updated successfully, but these errors were encountered: