Skip to content

Merge pull request #5444 from dannyKBjj/MSFT_IntuneAndroidManagedStor… #2535

Merge pull request #5444 from dannyKBjj/MSFT_IntuneAndroidManagedStor…

Merge pull request #5444 from dannyKBjj/MSFT_IntuneAndroidManagedStor… #2535

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@v3
with:
submodules: true
- uses: actions/setup-node@v3
with:
node-version: "16"
- 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@4
with:
name: website-build
path: ${{ github.workspace }}/generator/build
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@4
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