-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add GitHub action responsible for deployment of Blazor Web Assembly p…
…roject to GitHub pages
- Loading branch information
ivan_nizic
committed
Dec 9, 2024
1 parent
ed59f01
commit d3fb173
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
.github/workflows/deploy-blazor-wa-client-to-github-pages.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: Deploy Blazor WebAssembly to GitHub Pages | ||
|
||
on: | ||
workflow_dispatch: | ||
# Allows the workflow to be triggered manually | ||
|
||
jobs: | ||
build-and-deploy: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: '8.0.x' | ||
|
||
- name: Install dependencies and build | ||
run: | | ||
dotnet restore source/FlightScanner.Client.BlazorWA | ||
dotnet publish -c Release -o build source/FlightScanner.Client.BlazorWA | ||
- name: Deploy to GitHub Pages | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./build/wwwroot |