diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index f999f0d..d48324a 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -9,6 +9,10 @@ on: required: false type: boolean default: false + migrate: + required: false + type: boolean + default: false environment: type: string required: true @@ -48,6 +52,10 @@ jobs: done source .env cat .env + - name: Migrate + if: ${{ inputs.migrate == true }} + run: | + docker run -it --rm backend-users-test alembic upgrade head --env-file=.env - name: Deploy env: DOCKER_HOST: tcp://${{ inputs.host }}:2376