Release/v2.16.1 #86
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Dev release pipeline | |
on: | |
pull_request: | |
jobs: | |
sync_dev: | |
runs-on: ubuntu-latest | |
environment: | |
name: dev/${{ github.event.pull_request.number }} | |
url: https://ui-kit-open-source.dev.amity.co/${{ github.event.pull_request.number }} | |
env: | |
STORYBOOK_API_REGION: ${{ secrets.STORYBOOK_API_REGION }} | |
STORYBOOK_API_KEY: ${{ secrets.STORYBOOK_API_KEY }} | |
STORYBOOK_USER1: ${{ secrets.STORYBOOK_USER1 }} | |
STORYBOOK_USER2: ${{ secrets.STORYBOOK_USER2 }} | |
steps: | |
- name: git checkout | |
uses: actions/checkout@v2 | |
- name: install node | |
uses: actions/setup-node@v2 | |
- name: cache deps | |
uses: actions/cache@v2 | |
id: cache-deps | |
with: | |
path: | | |
**/node_modules | |
**/.eslintcache | |
key: node_modules-${{ hashFiles('**/package-lock.json') }} | |
- name: install deps | |
if: steps.cache-deps.outputs.cache-hit != 'true' | |
run: npm ci | |
- name: build storybook | |
run: npm run storybook:build | |
- name: publish on s3 | |
uses: jakejarvis/s3-sync-action@master | |
with: | |
args: --acl public-read --follow-symlinks --delete | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
AWS_S3_BUCKET: ui-kit-open-source.dev.amity.co | |
SOURCE_DIR: ./storybook-build | |
DEST_DIR: ${{ github.event.pull_request.number }} |