Merge pull request #6967 from FabienTschanz/feat/breaking-exo-active-… #3535
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: Build & Deploy to Production | |
| on: [push] | |
| jobs: | |
| build: | |
| if: github.repository == 'microsoft/Microsoft365DSC' && github.event.ref == 'refs/heads/Master' | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: PROD | |
| name: Build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| - uses: actions/setup-node@v3 | |
| with: | |
| node-version: "24" | |
| - name: Generate workloads and resources | |
| shell: pwsh | |
| run: pwsh -command ".\$GITHUB_WORKSPACE\generator\scripts\Build-Workloads.ps1 -Force" | |
| - name: Install packages | |
| run: | | |
| cd ${GITHUB_WORKSPACE}/generator | |
| npm install --force | |
| - name: Build generator | |
| run: | | |
| cd ${GITHUB_WORKSPACE}/generator | |
| npm run build | |
| env: | |
| REACT_APP_SITE_DESCRIPTION: ${{ secrets.REACT_APP_SITE_DESCRIPTION }} | |
| REACT_APP_INSTRUMENTATION_KEY: ${{ secrets.REACT_APP_INSTRUMENTATION_KEY }} | |
| - name: Publish Artifact | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: website-build | |
| path: ${{ github.workspace }}/generator/dist | |
| deploy_prod: | |
| if: github.repository == 'microsoft/Microsoft365DSC' && github.event.ref == 'refs/heads/Master' | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: PROD | |
| name: Deploy to Production | |
| needs: build | |
| steps: | |
| - uses: actions/download-artifact@v7 | |
| with: | |
| name: website-build | |
| - name: 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 }} | |
| action: "upload" | |
| app_location: "" | |
| output_location: "" | |
| skip_app_build: true |