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 Azure SQL Database schema' | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
types: [opened, synchronize, reopened, closed] | |
branches: | |
- main | |
jobs: | |
deploy_database_job: | |
if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed') | |
runs-on: ubuntu-latest | |
name: Deploy Database Job | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: Azure/[email protected] | |
with: | |
connection-string: ${{ secrets.AZURE_SQL_CONNECTION_STRING }} | |
# uses dacpac to deploy database schema | |
dacpac-package: './database/dacpac/bus-db.dacpac' |