From 517f6406667d90485733bc09bd38bb8c3063933f Mon Sep 17 00:00:00 2001 From: maro Date: Wed, 26 Aug 2026 00:33:10 +0200 Subject: [PATCH] Fix release deploy: give build-and-deploy a container with Docker CLI The runner (gitea-anouma-runner) runs as a Docker container itself (gitea/runner:3) with the host's docker.sock mounted in, but no `docker` CLI binary. A job with no `container:` runs directly inside that minimal runner image, so `docker login/build/push` failed with "docker: command not found". Using docker:27-cli gives the job the CLI; the runner mounts the same host socket into it automatically (sibling containers), and openssh-client is installed for the deploy step's ssh call. Co-Authored-By: Claude Sonnet 5 --- .gitea/workflows/release.yml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/release.yml b/.gitea/workflows/release.yml index 955825d..500a311 100644 --- a/.gitea/workflows/release.yml +++ b/.gitea/workflows/release.yml @@ -35,12 +35,23 @@ jobs: build-and-deploy: needs: test runs-on: ubuntu-latest - # No container here — this job needs the Docker CLI + an SSH client - # directly on the runner host, not inside a Node container. + # The anouma-runner runs as a Docker container itself (gitea/runner:3), + # with the host's docker.sock bind-mounted in but no `docker` CLI binary + # of its own — a job with no `container:` here runs directly inside that + # minimal runner image and gets "docker: command not found". Using the + # official Docker CLI image instead gives this job the `docker` binary, + # and the runner auto-mounts the same host docker.sock into it (sibling + # containers — see container.docker_host in the runner's config.yaml), + # so `docker build`/`push` operate on the host's real Docker daemon. + container: + image: docker:27-cli steps: - name: Checkout uses: actions/checkout@v4 + - name: Install ssh client + run: apk add --no-cache openssh-client + - name: Determine image tags id: image # Gitea Actions' runner is protocol-compatible with GitHub Actions,