Dockerfile.runner packages public/vectrum-runner.mjs on node:24-bookworm with Bun, git and the usual build tools, reading VECTRUM_URL and VECTRUM_RUNNER_TOKEN from the environment. Steps run as the node user inside the container, without access to the Docker socket. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Showing 1 changed file with 19 additions and 0 deletions.
| @@ -0,0 +1,19 @@ | ||
| 1 | + # A Vectrum runner in a container: Node.js, Bun, git and the usual build tools. | |
| 2 | + # | |
| 3 | + # docker build -f Dockerfile.runner -t vectrum-runner . | |
| 4 | + # docker run -d -e VECTRUM_URL=https://vectrum.example -e VECTRUM_RUNNER_TOKEN=vrn_… vectrum-runner | |
| 5 | + # | |
| 6 | + # Steps run as the unprivileged node user, inside this container only (no Docker socket). | |
| 7 | + FROM node:24-bookworm | |
| 8 | + COPY --from=oven/bun:1.4.2 /usr/local/bin/bun /usr/local/bin/bun | |
| 9 | + RUN ln -s /usr/local/bin/bun /usr/local/bin/bunx \ | |
| 10 | + && apt-get update && apt-get install -y --no-install-recommends tini && rm -rf /var/lib/apt/lists/* | |
| 11 | + | |
| 12 | + WORKDIR /runner | |
| 13 | + COPY --chown=node:node public/vectrum-runner.mjs ./ | |
| 14 | + RUN mkdir _work && chown node:node _work | |
| 15 | + USER node | |
| 16 | + | |
| 17 | + ENV VECTRUM_WORK_DIR=/runner/_work | |
| 18 | + ENTRYPOINT ["/usr/bin/tini", "--"] | |
| 19 | + CMD ["node", "vectrum-runner.mjs"] | |