Update storybook to add changeBackgroundReplacementImage (#960) #325
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: Deploy Components Demo App Workflow | |
on: | |
push: | |
branches: | |
- main | |
- 'release-**.x' | |
jobs: | |
deploy: | |
name: Deploy Demo App and Storybook | |
runs-on: ubuntu-latest | |
env: | |
AWS_DEFAULT_REGION: us-east-1 | |
AWS_DEFAULT_OUTPUT: text | |
AWS_ACCESS_KEY_ID: ${{secrets.AWS_ACCESS_KEY}} | |
AWS_SECRET_ACCESS_KEY: ${{secrets.AWS_SECRET_ACCESS_KEY}} | |
steps: | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
aws-region: us-east-1 | |
- name: Checkout Package | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Install SAM CLI | |
run: scripts/github-action-awscli-installation | |
- name: Setup Node environment | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 20 | |
- name: Get branch name | |
id: branch_name | |
run: | | |
branch=${{github.ref}} | |
branch=${branch#refs/heads/} | |
echo $branch | |
echo ::set-output name=branch_name::$branch | |
- name: Checkout amazon-chime-sdk repo | |
uses: actions/checkout@v2 | |
with: | |
repository: 'aws-samples/amazon-chime-sdk' | |
path: amazon-chime-sdk | |
ref: ${{steps.branch_name.outputs.branch_name}} | |
- name: Install latest version of React library and JS SDK in meeting demo | |
run: | | |
npm install | |
node ./scripts/update-sdk-version.js | |
- name: Deploy the Serverless Demo App | |
if: ${{ steps.branch_name.outputs.branch_name == 'main' }} | |
run: | | |
cd $GITHUB_WORKSPACE/amazon-chime-sdk/apps/meeting/serverless | |
node ./deploy.js -r us-east-1 -b chime-sdk-components-demo-canary -s chime-sdk-components-demo-canary -l | |
- name: Deploy the Serverless Demo App for Previous Major Version | |
if: ${{ steps.branch_name.outputs.branch_name != 'main' }} | |
run: | | |
cd $GITHUB_WORKSPACE/amazon-chime-sdk/apps/meeting/serverless | |
node ./deploy.js -r us-east-1 -b chime-sdk-components-demo-canary-prev -s chime-sdk-components-demo-canary-prev -l | |
- name: Check if need to deploy storybook | |
id: need_deploy | |
run: | | |
result=$(.github/script/need-deploy-storybook.js) | |
echo $result | |
echo ::set-output name=need_deploy::$result | |
- name: Publish Storybook Documentation | |
if: startsWith(steps.need_deploy.outputs.need_deploy, 'Deploy storybook') | |
run: npm run deploy-storybook -- --ci | |
env: | |
GH_TOKEN: chime-sdk-js-bot:${{ secrets.GITHUBPAGES}} |