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

Automated cherry pick of #10130: Add verify-cloudformation script #10131: Fix cloudformation lint errors #10132

Commits on Oct 28, 2020

  1. Add verify-cloudformation script

    This is an official AWS linter for cloudformation.
    It has already caught a few bugs in our cloudformation json generation logic
    rifelpet committed Oct 28, 2020
    Configuration menu
    Copy the full SHA
    f6ca2ec View commit details
    Browse the repository at this point in the history
  2. Fix cloudformation lint errors

    ```
    E3002 Invalid Property Resources/AWSAutoScalingAutoScalingGroupnodesmixedinstancesexamplecom/Properties/MixedInstancesPolicy/InstancesDistribution/SpotInstancePool
    //kops/tests/integration/update_cluster/mixed_instances_spot/cloudformation.json:321:13
    
    E3031 CidrIp contains invalid characters (Pattern: x.x.x.x/y) at Resources/AWSEC2SecurityGroupIngresssshexternaltonode2001085a348/Properties/CidrIp
    //kops/tests/integration/update_cluster/complex/cloudformation.json:833:9
    ```
    
    I'm using the strings.Contains to determine if a CIDR is v6 since it seems simplest given that we know the value wont have a port number [0]
    
    [0] https://stackoverflow.com/questions/22751035/golang-distinguish-ipv4-ipv6
    rifelpet committed Oct 28, 2020
    Configuration menu
    Copy the full SHA
    a8d08bc View commit details
    Browse the repository at this point in the history