diff --git a/.github/workflows/actions/build-docker-image/action.yml b/.github/workflows/actions/build-docker-image/action.yml index 64a5e706d5..f14f6abcea 100644 --- a/.github/workflows/actions/build-docker-image/action.yml +++ b/.github/workflows/actions/build-docker-image/action.yml @@ -23,6 +23,12 @@ inputs: description: Skip docker init (if ran after another invocation of this action) required: false default: '' + docker-user: + required: true + description: Docker Hub User + docker-password: + required: true + description: Docker Hub User runs: using: 'composite' @@ -44,8 +50,8 @@ runs: if: ${{ inputs.skip-init == '' }} with: registry: ghcr.io - username: ${{ secrets.DOCKER_MACHINE_USER }} - password: ${{ secrets.DOCKER_MACHINE_TOKEN }} + username: ${{ inputs.docker-user }} + password: ${{ inputs.docker-password }} - name: Build Runner Image uses: docker/build-push-action@v6 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6c0fb838c3..f59eb306db 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,6 +4,8 @@ on: workflows: ["Build infra images"] types: - completed + pull_request: + workflow_dispatch: jobs: prepare-matrix: @@ -102,3 +104,5 @@ jobs: build-args: | BUILD_CONTEXT=${{ steps.prepare_tags.outputs.context_dir }} INTEGRATION_VERSION=${{ steps.prepare_tags.outputs.version }} + docker-user: ${{ secrets.DOCKER_MACHINE_USER }} + docker-password: ${{ secrets.DOCKER_MACHINE_TOKEN }} diff --git a/.github/workflows/infra.yml b/.github/workflows/infra.yml index b63d7ca381..fe4fac875c 100644 --- a/.github/workflows/infra.yml +++ b/.github/workflows/infra.yml @@ -21,6 +21,9 @@ jobs: dockerfile: ./integrations/_infra/Dockerfile.base.builder platforms: linux/amd64,linux/arm64 tags: ghcr.io/port-labs/port-ocean-base-builder:latest + docker-user: ${{ secrets.DOCKER_MACHINE_USER }} + docker-password: ${{ secrets.DOCKER_MACHINE_TOKEN }} + - name: Build Docker Image uses: ./.github/workflows/actions/build-docker-image @@ -28,4 +31,6 @@ jobs: dockerfile: ./integrations/_infra/Dockerfile.base.runner platforms: linux/amd64,linux/arm64 tags: ghcr.io/port-labs/port-ocean-base-runner:latest + docker-user: ${{ secrets.DOCKER_MACHINE_USER }} + docker-password: ${{ secrets.DOCKER_MACHINE_TOKEN }} skip-init: 'yupp'