-
Notifications
You must be signed in to change notification settings - Fork 16
52 lines (43 loc) · 1.51 KB
/
azure-publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# Docs for the Azure Web Apps Deploy action: https://github.com/azure/functions-action
# More GitHub Actions for Azure: https://github.com/Azure/actions
name: Publish Azure Assets
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build-and-deploy:
runs-on: windows-latest
steps:
- name: 'Checkout GitHub Action'
uses: actions/checkout@v2
- name: Setup .NET Core 8.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 8.0.100
- name: Setup .NET Core 8.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: '8.0.x'
include-prerelease: true
- name: 'Build Functions'
run: dotnet build DevOps.Functions/DevOps.Functions.csproj --configuration Release --output ./artifacts/func
- name: 'Publish Function to Azure'
uses: Azure/functions-action@v1
id: fa
with:
app-name: 'runfo-func'
slot-name: 'production'
package: 'artifacts/func'
publish-profile: ${{ secrets.AzureAppService_PublishProfile_d880beb4d5a24b5f896e5e8987c41cee }}
- name: 'Build WebApp'
run: dotnet publish DevOps.Status/DevOps.Status.csproj --configuration Release --output ./artifacts/webapp
- name: 'Publish WebApp to Azure'
id: deploy-to-webapp
uses: azure/webapps-deploy@v2
with:
app-name: 'runfo'
slot-name: 'production'
publish-profile: ${{ secrets.AzureAppService_PublishProfile_20c71607d35440a982abc5c3456af5e7 }}
package: 'artifacts/webapp'