diff --git a/ci/template.yml b/ci/template.yml index 957325d2..fc7b6991 100644 --- a/ci/template.yml +++ b/ci/template.yml @@ -138,6 +138,8 @@ Resources: Resource: - !Sub arn:${AWS::Partition}:logs:${AWS::Region}:${AWS::AccountId}:log-group:/aws/codebuild/${CiCodeBuildProject} - !Sub arn:${AWS::Partition}:logs:${AWS::Region}:${AWS::AccountId}:log-group:/aws/codebuild/${CiCodeBuildProject}:* + - !Sub arn:${AWS::Partition}:logs:${AWS::Region}:${AWS::AccountId}:log-group:/aws/codebuild/${CiCodeBuildArmProject} + - !Sub arn:${AWS::Partition}:logs:${AWS::Region}:${AWS::AccountId}:log-group:/aws/codebuild/${CiCodeBuildArmProject}:* PolicyName: !Sub ${AWS::StackName}-CiCodeBuildLogsIamPolicy Roles: - !Ref CiCodeBuildIamRole @@ -148,7 +150,7 @@ Resources: Type: NO_ARTIFACTS Description: >- Unified CodeBuild project that handles CI testing and publishing for all - builds that enter the CI system + builds that enter the CI system for x64 destination architectures Environment: ComputeType: BUILD_GENERAL1_SMALL EnvironmentVariables: @@ -175,6 +177,40 @@ Resources: - { Key: prx:dev:application, Value: CI } TimeoutInMinutes: 16 + CiCodeBuildArmProject: + Type: AWS::CodeBuild::Project + Properties: + Artifacts: + Type: NO_ARTIFACTS + Description: >- + Unified CodeBuild project that handles CI testing and publishing for all + builds that enter the CI system for ARM destination architectures. + Environment: + ComputeType: BUILD_GENERAL1_SMALL + EnvironmentVariables: + - Name: PRX_AWS_ACCOUNT_ID + Value: !Ref AWS::AccountId + - Name: PRX_APPLICATION_CODE_BUCKET + Value: + Fn::ImportValue: !Sub ${InfrastructureStorageStackName}-InfrastructureApplicationCodeBucket + Image: aws/codebuild/amazonlinux2-x86_64-standard:5.0 + PrivilegedMode: true + Type: ARM_CONTAINER + Name: !Sub ${AWS::StackName}-ArmRunner + ServiceRole: !GetAtt CiCodeBuildIamRole.Arn + Source: + GitCloneDepth: 1 + Location: https://github.com/PRX/Infrastructure.git + ReportBuildStatus: true + Type: GITHUB + Tags: + - { Key: prx:meta:tagging-version, Value: "2021-04-07" } + - { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName } + - { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId } + - { Key: prx:ops:environment, Value: Production } + - { Key: prx:dev:application, Value: CI } + TimeoutInMinutes: 16 + GitHubWebhookEndpointFunction: Type: AWS::Serverless::Function Properties: