-
-
Save aflores/b91c989cd1d1113d0937dce8236121de to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# Docs for the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy | |
# More GitHub Actions for Azure: https://github.com/Azure/actions | |
name: Build and deploy ASP.Net Core app to Azure Web App - partsunlimited-web-20(staging) | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
build-and-deploy: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@main | |
- name: Set up .NET Core | |
uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: '2.2.207' | |
- name: Build with dotnet | |
run: dotnet build PartsUnlimited.sln --configuration Release | |
- name: dotnet publish | |
run: dotnet publish src/PartsUnlimitedWebsite/PartsUnlimitedWebsite.csproj -c Release -o ${{env.DOTNET_ROOT}}/myapp | |
- name: Deploy to Azure Web App | |
uses: azure/webapps-deploy@v2 | |
with: | |
app-name: 'partsunlimited-web-20' | |
slot-name: 'staging' | |
publish-profile: ${{ secrets.AzureAppService_PublishProfile_a00d49c7adc84a028ccc74ff431024d5 }} | |
package: ${{env.DOTNET_ROOT}}/myapp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment