Chore: Update devcontainer node js and install azure-function-core-tools from official sources #100
Workflow file for this run
This file contains hidden or 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
| name: Azure Static Web Apps CI/CD | |
| on: | |
| push: | |
| branches: | |
| - main | |
| # Eventually, deploy this to a staging environment | |
| # See: https://learn.microsoft.com/en-us/azure/static-web-apps/review-publish-pull-requests | |
| pull_request: | |
| types: [opened, synchronize, reopened, closed] | |
| branches: | |
| - main | |
| jobs: | |
| build_and_deploy_job: | |
| if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed') | |
| runs-on: ubuntu-latest | |
| environment: static-web-app | |
| name: Build and Deploy Job | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| # - name: Setup node | |
| # uses: actions/setup-node@v4 | |
| # with: | |
| # node-version: 18 | |
| - name: Install dependencies | |
| working-directory: swa/ | |
| run: | | |
| npm install | |
| - name: Build And Deploy | |
| id: builddeploy | |
| 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 }} # Used for GitHub integrations (i.e. PR comments) | |
| action: "upload" | |
| ###### Repository/Build Configurations - These values can be configured to match you app requirements. ###### | |
| # For more information regarding Static Web App workflow configurations, please visit: https://aka.ms/swaworkflowconfig | |
| api_location: "api" # Api source code path - optional | |
| app_location: "swa" # App source code path | |
| output_location: "dist/" # Built app content directory, relative to app_location - optional | |
| ###### End of Repository/Build Configurations ###### | |
| app_build_command: "npm run build" | |
| env: # Put a node version on the following line | |
| NODE_VERSION: 22 | |
| close_pull_request_job: | |
| if: github.event_name == 'pull_request' && github.event.action == 'closed' | |
| runs-on: ubuntu-latest | |
| environment: static-web-app | |
| name: Close Pull Request Job | |
| steps: | |
| - name: Close Pull Request | |
| id: closepullrequest | |
| uses: Azure/static-web-apps-deploy@v1 | |
| with: | |
| azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN }} | |
| action: "close" | |
| app_location: "swa" # App source code path | |