Merge pull request #15 from zentavious/karl/fix/safetensors-paths #13
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 | |
on: | |
push: | |
branches: | |
- main | |
# override default shell for mamba activation | |
defaults: | |
run: | |
shell: bash -el {0} | |
jobs: | |
deploy-lambdas: | |
name: Deploy to AWS | |
runs-on: ubuntu-latest | |
environment: production | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install environment | |
uses: prefix-dev/setup-pixi@v0.8.1 | |
with: | |
pixi-version: v0.29.0 | |
cache: false | |
environments: pkg | |
activate-environment: true | |
- name: Install Node dependencies | |
run: | | |
npm ci | |
- name: Cache model data | |
uses: actions/cache@v4 | |
with: | |
path: .dvc/cache | |
key: deploy-dvc-cache-${{ hashFiles('models/**.dvc') }} | |
- name: Deploy to Serverless | |
run: | | |
./deploy.sh -e "$STAGE" -r "$REGION" | |
env: | |
AWS_ACCESS_KEY_ID: ${{secrets.AWS_ACCESS_KEY_ID}} | |
AWS_SECRET_ACCESS_KEY: ${{secrets.AWS_SECRET_ACCESS_KEY}} | |
STAGE: prod | |
REGION: ${{vars.REGION}} |