cloudformation yaml 不断获取无效的主要格式

问题描述

我正在尝试使用 cloudformation 创建 KMS 密钥,但我不断收到错误消息,指出主体格式不正确。

我做错了什么?

  # KMS S3 Config Service encryption key
  snsconfigKey:
    Type: AWS::KMS::Key
    Properties:
      KeyPolicy:
        Version: 2012-10-17
        Id: key-snsconfig
        Statement:
          - Sid: Enable IAM User Permissions
            Effect: Allow
            Principal:
              AWS: !Join
                - ''
                - - 'arn:aws-us-gov:iam::'
                  - !Ref 'AWS::AccountId'
                  - ':user/Bob'

            Action: 'kms:*'
            Resource: '*'
  snsconfigKeyAlias:
    Type: AWS::KMS::Alias
    Properties:
      AliasName: alias/snsconfig
      TargetKeyId:
        Ref: snsconfigKey


解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)