Created
December 8, 2021 03:48
-
-
Save sylwit/f7e58cbce7b2b2ef74400531489ee8c8 to your computer and use it in GitHub Desktop.
Github workflow to deploy a static app on Backblaze
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: Build and deploy react app to Backblaze | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
react: | |
runs-on: ubuntu-latest | |
steps: | |
- actions/checkout@v2 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- run: yarn install | |
- run: yarn test | |
- run: yarn build | |
- uses: sylwit/install-b2-cli-action@v1.0.0 | |
env: | |
B2_APPLICATION_KEY_ID: ${{ secrets.B2_APPLICATION_KEY_ID }} | |
B2_APPLICATION_KEY: ${{ secrets.B2_APPLICATION_KEY }} | |
- name: deploy | |
run: b2 sync --delete --replaceNewer ./out b2://mybucket |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment