Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EC2.CfnNetworkAclEntry: can't specify IPv6 rule because "cidrBlock" required instead of optional #1517

Closed
mrcrowl opened this issue Jan 10, 2019 · 1 comment · Fixed by #1565
Labels
@aws-cdk/aws-cloudformation Related to AWS CloudFormation bug This issue is a bug.

Comments

@mrcrowl
Copy link

mrcrowl commented Jan 10, 2019

NetworkACLEntry docs indicates that only CidrBlock or Ipv6CidrBlock is required.

The TypeScript definition for CfnNetworkAclEntryProps has cidrBlock as required.

Reported error is:

Error: CfnNetworkAclEntry [ep/vpc/IPv6InboundACL] is missing required property: cidrBlock
    at Object.requireProperty (C:\WF\LP\cdk\node_modules\@aws-cdk\cdk\lib\runtime.js:319:15)
    at new CfnNetworkAclEntry (C:\WF\LP\cdk\node_modules\@aws-cdk\aws-ec2\lib\ec2.generated.js:4608:13)
    at VpcConstruct.configureNetworkACLs (C:\WF\LP\cdk\lib\vpc-construct.js:82:9)
    at new VpcConstruct (C:\WF\LP\cdk\lib\vpc-construct.js:17:14)
    at new EPStack (C:\WF\LP\cdk\lib\ep\ep-stack.js:8:9)
    at Object.<anonymous> (C:\WF\LP\cdk\bin\cdk.js:8:1)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)

If cidrBlock is ommitted, the error is:

C:\WF\LP\cdk\node_modules\@aws-cdk\cdk\lib\cloudformation\resource.js:163
            throw e;
            ^
While synthesizing ep/vpc/IPv6InboundACL: Supplied properties not correct for "CfnNetworkAclEntryProps"
  cidrBlock: required but missing
  --- resource created at ---
@rix0rrr
Copy link
Contributor

rix0rrr commented Jan 11, 2019

Interesting. Well the CloudFormation schema definitely says that CidrBlock is required, so we're going to have to patch that. Thanks for the report.

In the mean time, you should be able to specify a value for the property and then remove it again via CloudFormation overrides to work around this.

@rix0rrr rix0rrr added bug This issue is a bug. @aws-cdk/aws-cloudformation Related to AWS CloudFormation labels Jan 11, 2019
rix0rrr added a commit that referenced this issue Jan 17, 2019
The docs say this property is optional (exactly one of `CidrBlock`
and `ipv6CidrBlock` should be specified) but it's typed as `Required`
in the JSON schema.

Patch the schema until this is fixed upstream.

Fixes #1517.
rix0rrr added a commit that referenced this issue Jan 18, 2019
The docs say this property is optional (exactly one of `CidrBlock`
and `ipv6CidrBlock` should be specified) but it's typed as `Required`
in the JSON schema.

Patch the schema until this is fixed upstream.

Fixes #1517.
john-shaskin pushed a commit to john-shaskin/aws-cdk that referenced this issue Jan 23, 2019
The docs say this property is optional (exactly one of `CidrBlock`
and `ipv6CidrBlock` should be specified) but it's typed as `Required`
in the JSON schema.

Patch the schema until this is fixed upstream.

Fixes aws#1517.

Add MethodResponse support for aws-apigateway

Remove Dockerfile that was no longer needed

Update python base image from 3.6 to 3.6.5

Make the dockerfile work

Add MethodResponse support for aws-apigateway

Remove Dockerfile that was no longer needed

Update python base image from 3.6 to 3.6.5

Make the dockerfile work

Add MethodResponse to API Gateway Method.

Add some documentation to the MethodResponse properties. Update the test for MethodResponse with response models.

Fix some formatting and finish adding code documentation for MethodResponse.

Remove Dockerfile from this branch

Fix bad merge to methodresponse test.

Correct the MethodResponse response models documentation.

Add IModel type to reference when configuring a MethodResponse
sam-goodwin pushed a commit that referenced this issue Jan 28, 2019
The docs say this property is optional (exactly one of `CidrBlock`
and `ipv6CidrBlock` should be specified) but it's typed as `Required`
in the JSON schema.

Patch the schema until this is fixed upstream.

Fixes #1517.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-cloudformation Related to AWS CloudFormation bug This issue is a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants