3125 - Update to new Github auth (#139)

This commit is contained in:
Anders Gustafsson
2023-01-25 10:59:11 +01:00
committed by GitHub
parent 62b93a3656
commit 675f366025
2 changed files with 17 additions and 20 deletions
+15 -10
View File
@@ -81,11 +81,12 @@ Parameters:
Type: String
GitHubBranch:
Type: String
GitHubToken:
Type: String
NoEcho: true
GitHubUser:
# ARN for manually created github connection
# It cannot fully be setup in cloudformation (due to auth step on github end) and makes sense to reuse between stacks
GithubConnectionArn:
Type: String
Default: arn:aws:codestar-connections:eu-west-1:954747537408:connection/a5003038-5011-47d7-98ed-2ff15b290ab3
# Buckets
ImagesBucket:
@@ -456,6 +457,11 @@ Resources:
- codebuild:StartBuild
- codebuild:BatchGetBuilds
- iam:PassRole
- Resource:
- !Ref GithubConnectionArn
Effect: Allow
Action:
- codestar-connections:UseConnection
ArtifactBucket:
Type: AWS::S3::Bucket
@@ -531,14 +537,13 @@ Resources:
- Name: App
ActionTypeId:
Category: Source
Owner: ThirdParty
Owner: AWS
Version: 1
Provider: GitHub
Provider: CodeStarSourceConnection
Configuration:
Owner: !Ref GitHubUser
Repo: !Ref GitHubRepo
Branch: !Ref GitHubBranch
OAuthToken: !Ref GitHubToken
ConnectionArn: !Ref GithubConnectionArn
FullRepositoryId: !Ref GitHubRepo
BranchName: !Ref GitHubBranch
OutputArtifacts:
- Name: App
RunOrder: 1