-
Notifications
You must be signed in to change notification settings - Fork 2
81 lines (68 loc) · 3.04 KB
/
deploy.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# This is the main build pipeline that verifies and publishes the software
name: Environment Deployments
# Controls when the workflow will run
on:
# Triggers the workflow on push events
push:
branches: [main]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
# First job in the workflow installs and verifies the software
deploy_sit:
name: Deploy SIT
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_SERVICES_SIT }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_SERVICES_SIT }}
aws-region: us-west-2
role-session-name: GitHubActions
- run: aws sts get-caller-identity
- name: Sync S3
run: |
aws s3 sync ./config-files s3://podaac-services-sit-hitide/dataset-configs --delete --metadata githash=${GITHUB_SHA}
aws s3 sync ./palettes s3://podaac-services-sit-hitide/palettes --delete --metadata githash=${GITHUB_SHA}
deploy_uat:
name: Deploy UAT
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_SERVICES_UAT }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_SERVICES_UAT }}
aws-region: us-west-2
role-session-name: GitHubActions
- run: aws sts get-caller-identity
- name: Sync S3
run: |
aws s3 sync ./config-files s3://podaac-services-uat-hitide/dataset-configs --delete --metadata githash=${GITHUB_SHA}
aws s3 sync ./palettes s3://podaac-services-uat-hitide/palettes --delete --metadata githash=${GITHUB_SHA}
deploy_ops:
name: Deploy OPS
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_SERVICES_OPS }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_SERVICES_OPS }}
aws-region: us-west-2
role-session-name: GitHubActions
- run: aws sts get-caller-identity
- name: Sync S3
run: |
aws s3 sync ./config-files s3://podaac-services-ops-hitide/dataset-configs --delete --metadata githash=${GITHUB_SHA}
aws s3 sync ./palettes s3://podaac-services-ops-hitide/palettes --delete --metadata githash=${GITHUB_SHA}