Appliscale / perun

A command-line validation tool for AWS Cloud Formation that allows to conquer the cloud faster!
https://perun-for-aws.appliscale.io
Apache License 2.0
92 stars 8 forks source link

Fix Fn::ImportValue validation #160

Closed mwpolcik closed 5 years ago

mwpolcik commented 6 years ago

template example:

AWSTemplateFormatVersion: '2010-09-09'

Resources:

  MyEC2:
    Type: "AWS::EC2::Instance"
    Properties:
      ImageId: ami-1111111
      InstanceType: t2.medium
      SubnetId: subnet-1231231
      KeyName: something
      SecurityGroupIds:
      - Fn::ImportValue: some-export-id
      IamInstanceProfile: some-profile

Issue:

[1] % perun validate test.yml
INFO: Configuration file from the following location will be used: /Users/mpolcik16/.config/perun/main.yaml
INFO: Creating new session. Profile: aol Region: us-east-1
WARNING: MyEC2: SecurityGroupIds[0] <--- is nil.

Perun is not respecting Fn::ImportValue and it's deciding it is nil, when in fact it is a valid value.

Expected behaviour: validation should pass.

maxiwoj commented 6 years ago

Fix Fn::ImportValue validation

maxiwoj commented 5 years ago

closed by #174