{
  "Resources": {
    "MyRepoF4F48043": {
      "Type": "AWS::CodeCommit::Repository",
      "Properties": {
        "RepositoryName": "my-repo",
        "Triggers": []
      }
    },
    "PipelineArtifactsBucket22248F97": {
      "Type": "AWS::S3::Bucket",
      "DeletionPolicy": "Retain"
    },
    "PipelineRoleD68726F7": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Statement": [
            {
              "Action": "sts:AssumeRole",
              "Effect": "Allow",
              "Principal": {
                "Service": "codepipeline.amazonaws.com"
              }
            }
          ],
          "Version": "2012-10-17"
        }
      }
    },
    "PipelineRoleDefaultPolicyC7A05455": {
      "Type": "AWS::IAM::Policy",
      "Properties": {
        "PolicyDocument": {
          "Statement": [
            {
              "Action": [
                "s3:GetObject*",
                "s3:GetBucket*",
                "s3:List*",
                "s3:PutObject*",
                "s3:DeleteObject*",
                "s3:Abort*"
              ],
              "Effect": "Allow",
              "Resource": [
                {
                  "Fn::GetAtt": [
                    "PipelineArtifactsBucket22248F97",
                    "Arn"
                  ]
                },
                {
                  "Fn::Join": [
                    "",
                    [
                      {
                        "Fn::GetAtt": [
                          "PipelineArtifactsBucket22248F97",
                          "Arn"
                        ]
                      },
                      "/",
                      "*"
                    ]
                  ]
                }
              ]
            },
            {
              "Action": [
                "codecommit:GetBranch",
                "codecommit:GetCommit",
                "codecommit:UploadArchive",
                "codecommit:GetUploadArchiveStatus",
                "codecommit:CancelUploadArchive"
              ],
              "Effect": "Allow",
              "Resource": {
                "Fn::GetAtt": [
                  "MyRepoF4F48043",
                  "Arn"
                ]
              }
            }
          ],
          "Version": "2012-10-17"
        },
        "PolicyName": "PipelineRoleDefaultPolicyC7A05455",
        "Roles": [
          {
            "Ref": "PipelineRoleD68726F7"
          }
        ]
      }
    },
    "PipelineC660917D": {
      "Type": "AWS::CodePipeline::Pipeline",
      "Properties": {
        "ArtifactStore": {
          "Location": {
            "Ref": "PipelineArtifactsBucket22248F97"
          },
          "Type": "S3"
        },
        "RoleArn": {
          "Fn::GetAtt": [
            "PipelineRoleD68726F7",
            "Arn"
          ]
        },
        "Stages": [
          {
            "Actions": [
              {
                "ActionTypeId": {
                  "Category": "Source",
                  "Owner": "AWS",
                  "Provider": "CodeCommit",
                  "Version": "1"
                },
                "Configuration": {
                  "RepositoryName": {
                    "Fn::GetAtt": [
                      "MyRepoF4F48043",
                      "Name"
                    ]
                  },
                  "BranchName": "master",
                  "PollForSourceChanges": true
                },
                "InputArtifacts": [],
                "Name": "source",
                "OutputArtifacts": [
                  {
                    "Name": "SourceArtifact"
                  }
                ],
                "RunOrder": 1
              }
            ],
            "Name": "source"
          },
          {
            "Actions": [
              {
                "ActionTypeId": {
                  "Category": "Approval",
                  "Owner": "AWS",
                  "Provider": "Manual",
                  "Version": "1"
                },
                "InputArtifacts": [],
                "Name": "manual",
                "OutputArtifacts": [],
                "RunOrder": 1
              }
            ],
            "Name": "build"
          }
        ]
      },
      "DependsOn": [
        "PipelineRoleD68726F7",
        "PipelineRoleDefaultPolicyC7A05455"
      ]
    }
  }
}