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

Question - where is the ToolsAcctCodePipelineCodeCommitRole created? #17

Open
matwerber1 opened this issue Dec 11, 2020 · 1 comment
Open

Comments

@matwerber1
Copy link

matwerber1 commented Dec 11, 2020

Per link below:

- !Sub arn:aws:iam::${DevAccount}:role/ToolsAcctCodePipelineCodeCommitRole

I can't find where this role is actually created, e.g. AWS::IAM::Role in CloudFormation. Where is this coming from?

@hannonq
Copy link

hannonq commented Jan 18, 2021

Maybe a bit late, but if anyone else comes here with the same question, it is created here

In aws-refarch-cross-account-pipeline/DevAccount/toolsacct-codepipeline-codecommit.yaml:

Resources:
  Role:
    Type: AWS::IAM::Role
    Properties:
      RoleName: !Sub ToolsAcctCodePipelineCodeCommitRole
      AssumeRolePolicyDocument:
        Version: 2012-10-17
        Statement:
          -
            Effect: Allow
            Principal:
              AWS:
                - !Ref ToolsAccount
            Action:
              - sts:AssumeRole
      Path: /

The !Sub there is actually irrelevant (cfn-linter even gives this warning), since there is no variable to substitute. So the !Sub can be removed.

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

2 participants