Skip to content

Commit

Permalink
Update publish-app.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-stuart-cross committed Jan 23, 2024
1 parent fcd99fe commit 6017f06
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/publish-app.yml
Original file line number Diff line number Diff line change
@@ -1 +1,44 @@
name: publish

on:
push:
branches: [ working ]

env:
AZURE_WEBAPP_NAME: DotNetWeb
AZURE_WEBAPP_PACKAGE_PATH: '.' # Set this to the path to your web app project, defaults to the repository root:
DOTNET_VERSION: 8.0.x #'6.0.401' # The .NET SDK version to use

jobs:
publish:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Setup .NET Core
uses: actions/setup-dotnet@v3
with:
dotnet-version: ${{ env.DOTNET_VERSION }}

- name: Install dependencies
run: dotnet restore

- name: Build
run: |
cd Birder
dotnet build --configuration Release --no-restore
dotnet publish -c Release -o ./bin/publish
# dotnet publish -c Release -o ../dotnet-webapp -r linux-x64 --self-contained true /p:UseAppHost=true
- name: Test
# run: |
# cd DotNet.WebApp.Tests
# dotnet test --no-restore --verbosity normal
run: dotnet test --verbosity normal /p:CollectCoverage=true /p:CoverletOutputFormat=opencover --settings birder.tests/coverlet.runsettings.xml

- uses: azure/webapps-deploy@v2
name: Deploy
with:
app-name: ${{ env.AZURE_WEBAPP_NAME }}
publish-profile: ${{ secrets.AZURE_PUBLISH_PROFILE }}
package: '${{ env.AZURE_WEBAPP_PACKAGE_PATH }}/dotnet-webapp'

0 comments on commit 6017f06

Please sign in to comment.