Submatter/docker/opencode/Dockerfile
Randall Stillwell d90ff11f5b
Some checks are pending
CI / Lint, type-check, test (push) Waiting to run
Deploy homelab (CT 116) / Deploy to CT 116 (push) Waiting to run
feat(opencode): ship tooling image with git, node, and build deps
Extend the Alpine OpenCode base so agent sessions can clone, npm/pnpm
install, and compile native modules; seed Forgejo HTTPS creds at start.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 12:16:26 -05:00

31 lines
775 B
Docker

# OpenCode serve image + host tooling for interactive / worker agent sessions.
# Official image is Alpine and ships only the `opencode` binary.
FROM ghcr.io/anomalyco/opencode:latest
USER root
RUN apk add --no-cache \
bash \
ca-certificates \
curl \
git \
github-cli \
openssh-client \
ripgrep \
python3 \
make \
g++ \
libc6-compat \
nodejs \
npm \
&& curl -fsSL -o /usr/local/bin/pnpm \
https://github.com/pnpm/pnpm/releases/download/v9.15.9/pnpm-linuxstatic-x64 \
&& chmod +x /usr/local/bin/pnpm \
&& npm install -g tsx \
&& rm -rf /root/.npm/_cacache /tmp/*
ENV GIT_CONFIG_COUNT=1 \
GIT_CONFIG_KEY_0=safe.directory \
GIT_CONFIG_VALUE_0=*
WORKDIR /workspace