Skip to content

Commit

Permalink
ci: add workflows for deploy to azure
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlosPavajeau committed Aug 30, 2021
1 parent 0bbd99c commit e1f88fe
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/deploy-azure.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Deploy to Azure

on: [ release ]

env:
AZURE_WEBAPP_NAME: armoryapi
AZURE_WEBAPP_PACKAGE_PATH: '.'

jobs:
build:
runs-on: ubuntu-latest

steps:
# Checkout the repo
- uses: actions/checkout@main

- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.x

# Run dotnet build and publish
- name: dotnet build and publish
run: |
dotnet restore
dotnet build --configuration Release
dotnet publish -c Release -o '${{ env.AZURE_WEBAPP_PACKAGE_PATH }}/armory_out'
# Deploy to Azure Web apps
- name: 'Run Azure webapp deploy action using publish profile credentials'
uses: azure/webapps-deploy@v2
with:
app-name: ${{ env.AZURE_WEBAPP_NAME }}
publish-profile: ${{ secrets.AZURE_WEBAPP_PUBLISH_PROFILE }}
package: '${{ env.AZURE_WEBAPP_PACKAGE_PATH }}/armory_out'

0 comments on commit e1f88fe

Please sign in to comment.