-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (39 loc) · 1.59 KB
/
azure_deploy.yaml
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
name: Build and Deploy to Azure
on:
push:
branches:
- master
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: "8.0.x"
- name: Restore
run: dotnet restore ./backend.sln
- name: Build
run: dotnet build ./backend.sln --configuration Release --no-restore
- name: Publish
run: dotnet publish ./backend.sln --configuration Release --no-build --output './publish'
- name: Deploy to Azure
uses: azure/webapps-deploy@v2
with:
app-name: apekadeserver
publish-profile: ${{ secrets.AWPP }}
package: './publish'
- name: Deploy Summary
run: |
echo '### 🚀 Build and Deploy Summary' > $GITHUB_STEP_SUMMARY
echo '' >> $GITHUB_STEP_SUMMARY
echo '🔧 **Build Status**: The app has been successfully built.' >> $GITHUB_STEP_SUMMARY
echo '🚀 **Deploy Status**: The app has been successfully deployed to Azure.' >> $GITHUB_STEP_SUMMARY
echo '' >> $GITHUB_STEP_SUMMARY
echo '🛠️ **Solution**: backend.sln' >> $GITHUB_STEP_SUMMARY
echo '📦 **Build Configuration**: Release' >> $GITHUB_STEP_SUMMARY
echo '📂 **Output Directory**: ./publish' >> $GITHUB_STEP_SUMMARY
echo '🌍 **Azure App Name**: apekade-server' >> $GITHUB_STEP_SUMMARY
echo '' >> $GITHUB_STEP_SUMMARY
echo '🎉 **Thanks for using GitHub Actions!**' >> $GITHUB_STEP_SUMMARY