Skip to content

Deploy

Deploy #272

Workflow file for this run

name: Deploy
on:
push:
branches:
- master
workflow_dispatch:
workflow_run:
workflows: [CI]
types:
- completed
env:
REGISTRY: ghcr.io
NX_AFFECTED: true
NX_AFFECTED_BASE: origin/master
jobs:
affected-deployment:
name: Build and publish affected images
runs-on: ubuntu-latest
permissions: 'write-all'
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: nrwl/nx-set-shas@v3
with:
main-branch-name: 'master'
- name: Install dependencies
run: npm ci
- name: Log in to the Container registry
uses: docker/login-action@v1
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build & Push Affected Images to Registry
id: deploy-images-to-registry
run: |
npx nx affected -t "push-image-to-registry" --repository=${{ github.repository }} --github-sha="$GITHUB_SHA" --apiDomain=${{ secrets.API_DOMAIN }} --clientSideApiDomain=${{ secrets.CLIENTSIDE_API_DOMAIN }} --domain=${{ secrets.DOMAIN }}