This repository has been archived by the owner on Aug 12, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathCodeBuild.yml
50 lines (50 loc) · 1.6 KB
/
CodeBuild.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
AWSTemplateFormatVersion: '2010-09-09'
Description: CodeBuild CI
Parameters:
BuildImage:
AllowedValues:
- 'aws/codebuild/standard:3.0'
Description: Docker Image to use in CodeBuild Project
Type: String
ProjectName:
AllowedPattern: '^[a-zA-Z0-9-_]*$'
Description: 'Name to give the CodeBuild Project. For this sample, use the same name as your repository.'
MaxLength: '255'
MinLength: '2'
Type: String
RepositoryUrl:
Description: "HTTPS Clone URL of the repository in GitHub. Example: 'https://github.com/owner/repo.git'"
Type: String
Resources:
CodeBuildProject:
Type: 'AWS::CodeBuild::Project'
Properties:
Artifacts:
Type: NO_ARTIFACTS
Description: GitHub CI Build Project Sample
Environment:
ComputeType: BUILD_GENERAL1_SMALL
Image:
Ref: BuildImage
Type: LINUX_CONTAINER
Name:
Ref: ProjectName
ServiceRole:
Fn::ImportValue: codebuild-service-role
Source:
Location:
Ref: RepositoryUrl
Type: GITHUB
BuildSpec: 'buildspec.yml'
TimeoutInMinutes: 30
Tags:
-
Key: "venue"
Value: "reciter-workshop"
Outputs:
CodeBuildName:
Description: CodeBuild project
Value:
Ref: CodeBuildProject
Export:
Name: !Sub ${AWS::StackName}-codebuildProjectName