-
Notifications
You must be signed in to change notification settings - Fork 38
Expand file tree
/
Copy pathmaster_smallbasic-publicwebsite-code.yml
More file actions
53 lines (47 loc) · 1.79 KB
/
master_smallbasic-publicwebsite-code.yml
File metadata and controls
53 lines (47 loc) · 1.79 KB
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
53
# 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 to Caseysc`s Azure Web App - smallbasic-publicwebsite-code
on:
push:
branches:
- master
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 16.11.1
- uses: actions/setup-dotnet@v1.7.2
with:
dotnet-version: 2.1.816
- run: yarn --ci
working-directory: ./Source/SmallBasic.Client
- run: dotnet restore
- run: dotnet build ./SmallBasic.sln /p:TreatWarningsAsErrors=True /p:Configuration=Release
- run: dotnet publish ./Source/SmallBasic.Editor/SmallBasic.Editor.csproj --no-build /p:TreatWarningsAsErrors=True /p:Configuration=Release
- uses: actions/upload-artifact@v3.1.0
with:
path: /home/runner/work/smallbasic-editor/smallbasic-editor/Source/SmallBasic.Editor/bin/Release/netstandard2.0/publish/
if-no-files-found: error
deploy:
runs-on: windows-latest
needs: build
environment:
name: 'Production'
url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}
steps:
- name: Download artifact from build job
uses: actions/download-artifact@v2
with:
name: artifact
- name: Deploy to Azure Web App
id: deploy-to-webapp
uses: azure/webapps-deploy@v2
with:
app-name: 'smallbasic-publicwebsite-code'
slot-name: 'Production'
publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE_CC78D407C64043A1978FBF8A5FEDA312 }}
package: .