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

CloudFormation specific constructs are shown as invalid. #56

Open
msplival opened this issue Jul 26, 2024 · 1 comment
Open

CloudFormation specific constructs are shown as invalid. #56

msplival opened this issue Jul 26, 2024 · 1 comment

Comments

@msplival
Copy link

Here is excerpt from my CloudFormation template for some Aurora stack:

AuroraClusterKey:
    Type: AWS::KMS::Key
    Properties:
      Description: !Sub "KMS key for - ${DBName}"
      EnableKeyRotation: true
      KeyPolicy:
        Statement:
          - Sid: !Sub '${DBName} Aurora PG Cluster KMS key policy'
            Effect: Allow
            Principal:
              AWS:
                - !Sub arn:aws:iam::${AWS::AccountId}:root
            Action:
              - kms:*
            Resource: "*"

But, all of the !Sub sections are marked as 'Unresolved Tag'.

I am using v0.0.24, freshly installed into VSCode.

image

I suppose I am doing something wrong, but I can't determine what :)

@msplival
Copy link
Author

Ok, I'm silly enough not to read documentation properly. I had to include customTags snippet into my settiings.json file.

But I still have the issue, for this code snippet:

    Type: AWS::KMS::Alias
    Properties:
      AliasName: 
        !Sub 
         - "alias/rds/${clusterKeyDef}-key"
         - { clusterKeyDef: { Fn::ImportValue: !Sub '${MasterStack}:KMSKeyPrefix' } }
      TargetKeyId: !Ref AuroraClusterKey

The code deploys fine with aws cloudformation deploy. The !Sub is added as a custom tag via settings.json.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant