-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeploy.yml
More file actions
30 lines (29 loc) · 970 Bytes
/
Copy pathdeploy.yml
File metadata and controls
30 lines (29 loc) · 970 Bytes
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
parameters:
- name: awsCredentials
displayName: AWS Credentials
type: string
default: "AWS-Dev-AssumeRole"
- name: region
displayName: AWS Region
type: string
default: "ap-southeast-1"
steps:
- task: ECRPushImage@1
displayName: "Push Image to ECR"
inputs:
awsCredentials: "${{ parameters.awsCredentials }}"
regionName: "${{ parameters.region }}"
sourceImageName: "spms"
sourceImageTag: "$(Build.BuildId)"
repositoryName: "spms"
pushTag: "$(Build.BuildId)"
- script: |
cd SimplePasswordManagerService.Infra && cdk deploy SimplePasswordManagerServiceInfraStack \
--parameters "imageTag=$(Build.BuildId)" \
--parameters "secretArn=$(SPMS_SECRET_ARN)" \
--require-approval never
displayName: CDK Deploy
env:
AWS_ACCESS_KEY_ID: $(AWS_ACCESS_KEY_ID)
AWS_SECRET_ACCESS_KEY: $(AWS_SECRET_ACCESS_KEY)
AWS_DEFAULT_REGION: ${{ parameters.region }}