-
Notifications
You must be signed in to change notification settings - Fork 1
44 lines (35 loc) · 1.1 KB
/
deploy.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
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: Deploy to Github Pages
on:
push:
branches: [ "main" ]
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Build TailwindCSS
- uses: actions/setup-node@v4
with:
node-version: 18
- run: npm ci
- run: npm run deploy
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet publish -c Release -o release
# add .nojekyll file to tell GitHub pages to not treat this as a Jekyll project. (Allow files and folders starting with an underscore)
- name: Add .nojekyll file
run: touch release/wwwroot/.nojekyll
# deploys the app
- name: Deploy to Github Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: release/wwwroot # The release folder from build output