-
Notifications
You must be signed in to change notification settings - Fork 20
52 lines (41 loc) · 1.36 KB
/
staging.yaml
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
name: staging
on:
push:
branches:
- staging
env:
VERSION: TEST-SNAPSHOT
AWS_REGION: eu-south-1
jobs:
showcase-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "18.16.0"
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Run Ketchup build
run: npm run k:build
- name: Run Ketchup Showcase build
run: npm run ksc:build
- name: Zip artifacts
run: |
cd packages/ketchup/dist
zip -qr /tmp/ketchup.zip *
zip -qr /tmp/ketchup-components.zip ketchup/*
- name: Setup AWS
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ env.AWS_REGION }}
- name: Upload artifacts to AWS S3
run: |
aws s3 cp /tmp/ketchup.zip s3://smeup-ketchup/npm-pub/ketchup-stencil/${{ env.VERSION }}/zip/ketchup.zip
aws s3 cp /tmp/ketchup-components.zip s3://smeup-ketchup/npm-pub/ketchup-stencil/${{ env.VERSION }}/zip/ketchup-components.zip
- name: Upload showcase to AWS S3
run: aws s3 sync packages/ketchup-showcase/dist/ s3://smeup-ketchup/staging/ --delete