Skip to content

feat: 新增 IIS Express 及 iisSettings 至 launchSettings.json #2

feat: 新增 IIS Express 及 iisSettings 至 launchSettings.json

feat: 新增 IIS Express 及 iisSettings 至 launchSettings.json #2

name: Deploy (Azure Static Web Apps)

Check failure on line 1 in .github/workflows/deploy-azure-swa.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/deploy-azure-swa.yml

Invalid workflow file

(Line: 33, Col: 13): Unrecognized named-value: 'secrets'. Located at position 1 within expression: secrets.AZURE_STATIC_WEB_APPS_API_TOKEN != '', (Line: 44, Col: 13): Unrecognized named-value: 'secrets'. Located at position 1 within expression: secrets.AZURE_STATIC_WEB_APPS_API_TOKEN == ''
on:
workflow_dispatch:
push:
branches:
- main
- master
permissions:
contents: read
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '10.0.x'
- name: Publish (Azure SWA)
shell: pwsh
run: |
./specs/001-add-wasm-hosting/scripts/publish-browser-hosted.ps1 \
-Platform azure-swa \
-Configuration Release
- name: Deploy to Azure Static Web Apps
if: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN != '' }}
uses: Azure/static-web-apps-deploy@v1
with:
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN }}
repo_token: ${{ secrets.GITHUB_TOKEN }}
action: upload
app_location: ReleaseDownload/browser-hosted/azure-swa/Release/wwwroot
skip_app_build: true
skip_api_build: true
- name: Skipped (missing token)
if: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN == '' }}
run: |
echo "AZURE_STATIC_WEB_APPS_API_TOKEN is not set; skipping deploy."