Skip to content

Deploy to Development by @dharmesh-hemaram on config-release #6

Deploy to Development by @dharmesh-hemaram on config-release

Deploy to Development by @dharmesh-hemaram on config-release #6

Workflow file for this run

name: mono-repo [deploy - configs]
run-name: Deploy to Development by @${{ github.actor }} on ${{github.ref_name }}
on:
workflow_dispatch:
jobs:
main:
name: Build & Bundle
environment: Development
runs-on: ubuntu-latest
permissions:
contents: write
actions: read
discussions: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v4
with:
node-version: 20
registry-url: https://npm.pkg.github.com
scope: ${{github.repository_owner}}
cache: 'npm'
- uses: nrwl/nx-set-shas@v3
- run: |
echo "BASE: ${{ env.NX_BASE }}"
echo "HEAD: ${{ env.NX_HEAD }}"
- run: npm ci
- name: Build Projects and Library
run: npx nx build acf-configs --prod --verbose
env:
NX_PUBLIC_FIREBASE_API_KEY: ${{vars.NX_PUBLIC_FIREBASE_API_KEY}}
NX_PUBLIC_FIREBASE_DATABASE_URL: ${{vars.NX_PUBLIC_FIREBASE_DATABASE_URL}}
NX_PUBLIC_FIREBASE_PROJECT_ID: ${{vars.NX_PUBLIC_FIREBASE_PROJECT_ID}}
NX_PUBLIC_FIREBASE_BUCKET: ${{vars.NX_PUBLIC_FIREBASE_BUCKET}}
NX_PUBLIC_FIREBASE_AUTH_DOMAIN: ${{vars.NX_PUBLIC_FIREBASE_AUTH_DOMAIN}}
- name: Print Environment Info
run: npx nx report
- name: Bundle Projects
run: |
mkdir bundle
cd dist/apps/acf-configs
zip -r ../../../bundle/acf-configs-${{vars.NX_PUBLIC_VARIANT}}.zip .
cd ..
- uses: actions/upload-artifact@v4
id: artifact-upload-step
with:
name: nx-main-artifacts
path: |
bundle/*
firebase.json
.firebaserc
config:
name: Deploy Config
needs: [main]
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
environment:
name: Development
url: https://configs.getautoclicker.com
steps:
- uses: actions/download-artifact@v4
with:
name: nx-main-artifacts
- name: unzip
run: unzip bundle/acf-configs-${{vars.NX_PUBLIC_VARIANT}}.zip -d acf-configs
- name: Files
run: ls -la
- name: Build And Deploy
id: deploy
uses: FirebaseExtended/action-hosting-deploy@v0
with:
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT }}'
projectId: auto-clicker-autofill
channelId: live