-
Notifications
You must be signed in to change notification settings - Fork 24
43 lines (37 loc) · 1.09 KB
/
ci.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
name: CI
on:
push:
branches:
- master
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
steps:
- uses: actions/checkout@v4
- name: Use Node.js 14
uses: actions/setup-node@v4
with:
node-version: '14'
- run: npm install
- run: npm run lint
- run: npm run build
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: ${{ vars.DEVREL_GH_OIDC_ROLE_ARN }}
aws-region: eu-west-1
role-session-name: GitHub-OIDC-docs-ui
- name: Sync UI Bundle to S3
env:
AWS_S3_BUCKET: ${{ secrets.STATIC_CONTENT_BUCKET }}
# if the AWS_S3_BUCKET is undefined, the task will fail
# also make sure that we are on master before publishing the "latest" version
if: ${{ env.AWS_S3_BUCKET != '' && github.ref == 'refs/heads/master' }}
run: |
aws s3 sync --follow-symlinks --include '*.zip' --no-progress build s3://${{ secrets.STATIC_CONTENT_BUCKET }}/build