diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index cbbb9a8379877..bd3fa3730c0dd 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -8,6 +8,24 @@ on: types: [synchronize, opened, reopened, ready_for_review] jobs: + config: + runs-on: "ubuntu-latest" + if: github.event.pull_request.draft == false + outputs: + has-secrets: ${{ steps.check.outputs.has-secrets }} + steps: + - name: "Check for secrets" + id: check + shell: bash + run: | + if [ -n "${{ (secrets.DOCKERHUB_USER != '' && secrets.DOCKERHUB_TOKEN != '') || '' }}" ]; then + echo "has-secrets=1" >> "$GITHUB_OUTPUT" + echo "has secrets!" + else + echo "has-secrets=0" >> "$GITHUB_OUTPUT" + echo "no secrets!" + fi + docker-build: if: github.event.pull_request.draft == false name: docker-build