Skip to content

CQ image

CQ image #22

Workflow file for this run

# Find full documentation here https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions
name: CQ image
on:
pull_request:
paths:
- 'containers/cloudquery/**'
push:
branches:
- main
paths:
- 'containers/cloudquery/**'
# Manual invocation.
workflow_dispatch:
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}/cloudquery
# Ensure we only ever have one build running at a time.
# If we push twice in quick succession, the first build will be stopped once the second starts.
# This avoids any race conditions.
concurrency:
group: ${{ github.ref }}/cloudquery
cancel-in-progress: true
jobs:
CQ_CLI:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.2
- name: Set CQ_CLI
run: |
source .env
echo $CQ_CLI
echo "CQ_CLI=${CQ_CLI}" >> "$GITHUB_ENV"
outputs:
CQ_CLI: ${{ env.CQ_CLI }}
build-and-push:
needs: CQ_CLI
uses: guardian/service-catalogue/.github/workflows/release-image.yml@nt-ac/workflow
with:
IMAGE_NAME: prisma-migrate
BUILD_ARGS: CQ_CLI=${{ needs.CQ_CLI.outputs.CQ_CLI }}
permissions:
contents: read
packages: write