ci: switch to cargo install for trunk #28
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: Shuttle Deploy | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }}-shuttle-deploy | |
cancel-in-progress: true | |
on: | |
push: | |
branches: | |
- main | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
# https://docs.github.com/en/actions/sharing-automations/reusing-workflows#calling-a-reusable-workflow | |
run_tests: | |
uses: ./.github/workflows/general.yml | |
deploy: | |
runs-on: ubuntu-latest | |
needs: run_tests | |
steps: | |
- uses: wykies/checkout@main | |
- uses: wykies/setup-rust-toolchain@main | |
- name: Load sqlx query files for shuttle version | |
run: cargo run --bin switch-db -- --no-edit-only-copy shuttle | |
- name: Install Trunk | |
run: cargo install --locked trunk | |
- name: Build client | |
run: ./scripts/build_chat_client.sh | |
- name: Include git diff for debug | |
run: git diff | |
- name: Include git status for debug | |
run: git status | |
- uses: shuttle-hq/deploy-action@v2 | |
with: | |
shuttle-api-key: ${{ secrets.SHUTTLE_API_KEY }} | |
project-id: ${{ secrets.SHUTTLE_PROJ_ID }} |