-
-
Notifications
You must be signed in to change notification settings - Fork 6
43 lines (35 loc) · 1.36 KB
/
deploy-schema.yml
File metadata and controls
43 lines (35 loc) · 1.36 KB
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: Deploy JSON schema
on:
workflow_dispatch:
push:
paths:
- "schema.json"
- ".github/workflows/deploy-schema.yml"
branches:
- "main"
concurrency:
# Skip intermediate builds: all builds except for builds on the `master` branch
# Cancel intermediate builds: only pull request builds
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/main' || github.run_number }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
permissions:
contents: read
env:
aws_region: us-east-1
s3_bucket: julialang2
jobs:
deploy-schema:
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # 6.0.2
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@ec61189d14ec14c8efccab744f656cffd0e33f37 # 6.1.0
with:
aws-access-key-id: ${{ secrets.AWS_DEPLOY_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_DEPLOY_SECRET_ACCESS_KEY }}
aws-region: ${{ env.aws_region }}
- name: Upload schema.json as versions-schema.json to s3
run: aws s3 cp schema.json s3://${{ env.s3_bucket }}/bin/versions-schema.json --acl public-read --no-progress
- name: Purge cache
run: curl -X PURGE https://julialang-s3.julialang.org/bin/versions-schema.json