Skip to content

import updated

import updated #53

Workflow file for this run

name: CldCvr Flow to S3
on:
push:
branches:
- main
defaults:
run:
shell: bash
working-directory: .
env:
DISTRIBUTION_ID: E2ZI9E4QTG3PZ9
BUCKET_NAME: flow.ollion.com
AWS_REGION: us-east-1
ROLE_NAME: flow.ollion.com-role
ACCOUNT_ID: 679519065279
jobs:
build:
name: Upload to Amazon S3
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Node.js 16.x
uses: actions/setup-node@v2
with:
node-version: 16.x
- name: Install pnpm
run: corepack enable && corepack prepare [email protected] --activate
- name: Install Dependencies and Build
run: export NODE_OPTIONS="--max_old_space_size=8192" && pnpm i && pnpm run build-storybook
- name: Configure AWS credentials from Test account
uses: aws-actions/configure-aws-credentials@v1
with:
role-to-assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/${{env.ROLE_NAME}}
aws-region: ${{env.AWS_REGION}}
- name: Check Access
run: |
aws sts get-caller-identity
- name: Copy files to the website with the AWS CLI
run: |
aws s3 sync storybook-static/ s3://${{env.BUCKET_NAME}}/templates/
- name: Invalidate CloudFront
run: |
aws cloudfront create-invalidation --distribution-id ${{env.DISTRIBUTION_ID}} --paths "/*"