You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/031-build-deploy-webapp-to-azure.yml
+14-31Lines changed: 14 additions & 31 deletions
Original file line number
Diff line number
Diff line change
@@ -1,38 +1,19 @@
1
-
# This workflow will build and push a .NET Core app to an Azure Web App when a commit is pushed to your default branch.
2
-
#
3
-
# This workflow assumes you have already created the target Azure App Service web app.
4
-
# For instructions see https://docs.microsoft.com/en-us/azure/app-service/quickstart-dotnetcore?tabs=net60&pivots=development-environment-vscode
5
-
#
6
-
# To configure this workflow:
7
-
#
8
-
# 1. Download the Publish Profile for your Azure Web App. You can download this file from the Overview page of your Web App in the Azure Portal.
9
-
# For more information: https://docs.microsoft.com/en-us/azure/app-service/deploy-github-actions?tabs=applevel#generate-deployment-credentials
10
-
#
11
-
# 2. Create a secret in your repository named AZURE_WEBAPP_PUBLISH_PROFILE, paste the publish profile contents as the value of the secret.
12
-
# For instructions on obtaining the publish profile see: https://docs.microsoft.com/azure/app-service/deploy-github-actions#configure-the-github-secret
13
-
#
14
-
# 3. Change the value for the AZURE_WEBAPP_NAME. Optionally, change the AZURE_WEBAPP_PACKAGE_PATH and DOTNET_VERSION environment variables below.
15
-
#
16
-
# For more information on GitHub Actions for Azure: https://github.com/Azure/Actions
17
-
# For more information on the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy
18
-
# For more samples to get started with GitHub Action workflows to deploy to Azure: https://github.com/Azure/actions-workflow-samples
19
-
20
1
name: 031-build-deploy-webapp-to-azure
21
2
22
3
env:
23
-
AZURE_WEBAPP_NAME: appservice-enis# set this to the name of your Azure Web App
24
-
DOTNET_VERSION: '6.0.x'# set this to the .NET Core version to use
4
+
AZURE_WEBAPP_NAME: appservice-enis
5
+
DOTNET_VERSION: '6.0.x'
25
6
26
7
on:
27
8
push:
28
-
branches:none
29
-
#- main
9
+
branches:
10
+
- main# fixed (was invalid: branches: none)
30
11
workflow_dispatch:
31
12
32
13
jobs:
33
14
build:
34
15
runs-on: ubuntu-latest
35
-
16
+
36
17
defaults:
37
18
run:
38
19
working-directory: 03-app-dotnet
@@ -41,9 +22,10 @@ jobs:
41
22
- uses: actions/checkout@v4
42
23
43
24
- name: Set up .NET Core
44
-
uses: actions/setup-dotnet@v3
25
+
uses: actions/setup-dotnet@v3
26
+
with: # ✅ FIX: missing "with"
45
27
dotnet-version: ${{ env.DOTNET_VERSION }}
46
-
28
+
47
29
- name: Set up dependency caching for faster builds
0 commit comments