From aba6c5ed549694107bb453057d4f3a21e3940574 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 5 Aug 2026 09:47:30 +0000 Subject: [PATCH 1/4] nodejs: install opencode via npm to fix flaky CI The curl installer fetches the latest version from the unauthenticated GitHub API, which is rate-limited on shared Actions runner IPs. Failures were swallowed by '|| true', leaving a dangling /usr/local/bin/opencode symlink and failing the 'opencode --version' test only after the build. Install the opencode-ai npm package instead (npm registry only, no GitHub API) and verify the binary during the build. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01S9abShYK5RMmbeuZurGH3b --- nodejs/Dockerfile | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/nodejs/Dockerfile b/nodejs/Dockerfile index 8324331..99b1a39 100644 --- a/nodejs/Dockerfile +++ b/nodejs/Dockerfile @@ -45,14 +45,9 @@ RUN \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ chmod +x /home/coder/.local/bin/claude 2>/dev/null || true && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ - # OPENCODE ################################################################## - (curl -fsSL https://opencode.ai/install | bash || true) && \ - mkdir -p /home/coder/.opencode/bin && \ - if [ -f /root/.opencode/bin/opencode ]; then cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode; fi && \ - chmod +x /home/coder/.opencode/bin/opencode 2>/dev/null || true && \ - ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ - # NPM: CODEX, COPILOT ####################################################### - npm install -g @openai/codex @github/copilot && \ + # NPM: OPENCODE, CODEX, COPILOT ############################################# + npm install -g opencode-ai @openai/codex @github/copilot && \ + opencode --version && \ # PI ######################################################################## npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ # AGENT-BROWSER ############################################################## @@ -66,14 +61,14 @@ RUN \ echo '[ -d "$DENO_INSTALL/bin" ] && export PATH="$DENO_INSTALL/bin:$PATH"' >> /etc/profile && \ echo '[ -d "$BUN_INSTALL/bin" ] && export PATH="$BUN_INSTALL/bin:$PATH"' >> /etc/profile && \ # OWNERSHIP ################################################################ - chown -R coder:coder /home/coder/.local /home/coder/.opencode 2>/dev/null || true && \ + chown -R coder:coder /home/coder/.local 2>/dev/null || true && \ # CLEANUP ################################################################### apt-get clean -y && \ apt-get autoclean -y && \ apt-get remove -y wget && \ apt-get autoremove -y && \ rm -rf /var/lib/apt/lists/* /var/lib/log/* /tmp/* /var/tmp/* \ - /root/.npm /root/.cache /root/.local /root/.opencode /root/.bun + /root/.npm /root/.cache /root/.local /root/.bun WORKDIR /home/coder From 66b59b8c28db6d25190ba06fbc95642d7c5ee0c1 Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 6 Aug 2026 16:29:31 +0000 Subject: [PATCH 2/4] Fix image builds on Ubuntu resolute base and harden opencode install The codercom/enterprise-base:ubuntu image moved to Ubuntu resolute, which broke fx and php builds in two compounding ways: 1. ppa:ondrej/php publishes no release for resolute (404). PHP 8.5 and all needed extensions are now in the native Ubuntu archive, so drop the PPA (and software-properties-common, only needed for it). php8.5-imap is dropped: the imap extension was unbundled from PHP core in 8.4 and no package exists for resolute. 2. The failure was masked by an unparenthesized 'chown ... || true' near the end of the RUN chain: && and || have equal precedence, so that '|| true' rescued the failed apt-get update, skipped every install step in between, and produced a 'successful' image with no node/php inside. Ownership chowns are now plain commands (their targets always exist) and the claude chmod fallbacks are parenthesized, so a mid-chain failure fails the build. opencode is now installed with a pinned version (ENV OPENCODE_VERSION, matching the GLAB_VERSION convention) instead of 'latest': - deterministic: skips the unauthenticated api.github.com 'latest' lookup that gets rate-limited on shared Actions runners (the original nodejs failure) and downloads the release tarball directly - the binary stays in /home/coder/.opencode/bin owned by coder, so the coder user can still run 'opencode upgrade' (replaces the earlier npm-based approach, which put a root-owned binary in /usr/lib) - no '|| true': a failed install now fails the build, and 'opencode --version' verifies the binary at build time Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01S9abShYK5RMmbeuZurGH3b --- fx/Dockerfile | 22 ++++++++++++---------- golang/Dockerfile | 14 +++++++++----- nodejs/Dockerfile | 19 ++++++++++++++----- php/Dockerfile | 25 ++++++++++++++----------- python/Dockerfile | 14 +++++++++----- 5 files changed, 58 insertions(+), 36 deletions(-) diff --git a/fx/Dockerfile b/fx/Dockerfile index 10a4ccc..90fb996 100644 --- a/fx/Dockerfile +++ b/fx/Dockerfile @@ -5,6 +5,7 @@ ENV BUN_INSTALL=/usr/local ENV NODE_VERSION=24 ENV GO_VERSION=1.26.5 ENV GLAB_VERSION=1.111.0 +ENV OPENCODE_VERSION=1.18.13 ENV GOROOT=/usr/local/go ENV GOPATH=/home/coder/go ENV PATH=$GOROOT/bin:$GOPATH/bin:$PATH @@ -25,11 +26,9 @@ RUN \ # REPOS #################################################################### # Add all package repos first, then do a single apt-get update apt-get update && \ - apt-get install -y --no-install-recommends curl wget software-properties-common gpg && \ + apt-get install -y --no-install-recommends curl wget gpg && \ # Node repo curl -fsSL "https://deb.nodesource.com/setup_${NODE_VERSION}.x" | bash - && \ - # PHP repo - add-apt-repository -y ppa:ondrej/php && \ # GitHub CLI repo wget -qO /tmp/githubcli-archive-keyring.gpg https://cli.github.com/packages/githubcli-archive-keyring.gpg && \ mkdir -p -m 755 /etc/apt/keyrings && \ @@ -43,8 +42,9 @@ RUN \ git jq ripgrep tmux \ # Node nodejs \ - # PHP - php8.5-cli php8.5-common php8.5-curl php8.5-gd php8.5-imap php8.5-intl \ + # PHP (native Ubuntu packages; ondrej PPA has no release for this Ubuntu + # version and php8.5-imap no longer exists — imap was unbundled in 8.4) + php8.5-cli php8.5-common php8.5-curl php8.5-gd php8.5-intl \ php8.5-mailparse php8.5-mbstring php8.5-mysql php8.5-pgsql php8.5-phpdbg \ php8.5-readline php8.5-redis php8.5-soap php8.5-sqlite3 php8.5-xml \ php8.5-zip php8.5-bcmath php8.5-apcu php8.5-imagick \ @@ -88,9 +88,11 @@ RUN \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /usr/local/bin/claude; fi && \ chmod 0755 /usr/local/bin/claude && \ # OPENCODE ################################################################## - (curl -fsSL https://opencode.ai/install | bash || true) && \ - if [ -f /root/.opencode/bin/opencode ]; then cp /root/.opencode/bin/opencode /usr/local/bin/opencode; fi && \ + # Pinned version: avoids the rate-limited api.github.com "latest" lookup. + curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ + cp /root/.opencode/bin/opencode /usr/local/bin/opencode && \ chmod 0755 /usr/local/bin/opencode && \ + opencode --version && \ # NPM: CODEX, COPILOT ####################################################### npm install -g @openai/codex @github/copilot && \ # PI ######################################################################## @@ -119,12 +121,12 @@ RUN \ echo 'export XDG_RUNTIME_DIR="${XDG_RUNTIME_DIR:-/run/user/$(id -u)}"' >> /etc/profile && \ echo 'export DOCKER_HOST="unix://${XDG_RUNTIME_DIR}/docker.sock"' >> /etc/profile && \ # OWNERSHIP (coder can upgrade tools) ###################################### - chown coder:coder /usr/local/bin/claude /usr/local/bin/opencode 2>/dev/null || true && \ - chown -R coder:coder /home/coder/go 2>/dev/null || true && \ + chown coder:coder /usr/local/bin/claude /usr/local/bin/opencode && \ + chown -R coder:coder /home/coder/go && \ # CLEANUP ################################################################### apt-get clean -y && \ apt-get autoclean -y && \ - apt-get remove -y wget software-properties-common && \ + apt-get remove -y wget && \ apt-get autoremove -y && \ rm -rf /var/lib/apt/lists/* /var/lib/log/* /tmp/* /var/tmp/* \ /root/.npm /root/.cache /root/.local /root/.opencode /root/.bun diff --git a/golang/Dockerfile b/golang/Dockerfile index 85c7d9c..615848e 100644 --- a/golang/Dockerfile +++ b/golang/Dockerfile @@ -3,6 +3,7 @@ FROM codercom/enterprise-base:ubuntu ENV NODE_VERSION=24 ENV GO_VERSION=1.26.5 ENV GLAB_VERSION=1.111.0 +ENV OPENCODE_VERSION=1.18.13 ENV GOROOT=/usr/local/go ENV GOPATH=/home/coder/go ENV PATH=$GOROOT/bin:$GOPATH/bin:$PATH @@ -47,14 +48,17 @@ RUN \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ - chmod +x /home/coder/.local/bin/claude 2>/dev/null || true && \ + (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - (curl -fsSL https://opencode.ai/install | bash || true) && \ + # Pinned version: avoids the rate-limited api.github.com "latest" lookup. + # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. + curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ - if [ -f /root/.opencode/bin/opencode ]; then cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode; fi && \ - chmod +x /home/coder/.opencode/bin/opencode 2>/dev/null || true && \ + cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ + chmod 0755 /home/coder/.opencode/bin/opencode && \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ + opencode --version && \ # NPM: CODEX, COPILOT ####################################################### npm install -g @openai/codex @github/copilot && \ # PI ######################################################################## @@ -69,7 +73,7 @@ RUN \ echo 'export GOPATH="$HOME/go"' >> /etc/profile && \ echo 'export PATH="$GOROOT/bin:$GOPATH/bin:$PATH"' >> /etc/profile && \ # OWNERSHIP ################################################################ - chown -R coder:coder /home/coder/.local /home/coder/.opencode /home/coder/go 2>/dev/null || true && \ + chown -R coder:coder /home/coder/.local /home/coder/.opencode /home/coder/go && \ # CLEANUP ################################################################### apt-get clean -y && \ apt-get autoclean -y && \ diff --git a/nodejs/Dockerfile b/nodejs/Dockerfile index 99b1a39..cf59160 100644 --- a/nodejs/Dockerfile +++ b/nodejs/Dockerfile @@ -4,6 +4,7 @@ ENV DENO_INSTALL=/usr/local ENV BUN_INSTALL=/usr/local ENV NODE_VERSION=24 ENV GLAB_VERSION=1.111.0 +ENV OPENCODE_VERSION=1.18.13 USER root @@ -43,11 +44,19 @@ RUN \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ - chmod +x /home/coder/.local/bin/claude 2>/dev/null || true && \ + (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ - # NPM: OPENCODE, CODEX, COPILOT ############################################# - npm install -g opencode-ai @openai/codex @github/copilot && \ + # OPENCODE ################################################################## + # Pinned version: avoids the rate-limited api.github.com "latest" lookup. + # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. + curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ + mkdir -p /home/coder/.opencode/bin && \ + cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ + chmod 0755 /home/coder/.opencode/bin/opencode && \ + ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ opencode --version && \ + # NPM: CODEX, COPILOT ####################################################### + npm install -g @openai/codex @github/copilot && \ # PI ######################################################################## npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ # AGENT-BROWSER ############################################################## @@ -61,14 +70,14 @@ RUN \ echo '[ -d "$DENO_INSTALL/bin" ] && export PATH="$DENO_INSTALL/bin:$PATH"' >> /etc/profile && \ echo '[ -d "$BUN_INSTALL/bin" ] && export PATH="$BUN_INSTALL/bin:$PATH"' >> /etc/profile && \ # OWNERSHIP ################################################################ - chown -R coder:coder /home/coder/.local 2>/dev/null || true && \ + chown -R coder:coder /home/coder/.local /home/coder/.opencode && \ # CLEANUP ################################################################### apt-get clean -y && \ apt-get autoclean -y && \ apt-get remove -y wget && \ apt-get autoremove -y && \ rm -rf /var/lib/apt/lists/* /var/lib/log/* /tmp/* /var/tmp/* \ - /root/.npm /root/.cache /root/.local /root/.bun + /root/.npm /root/.cache /root/.local /root/.opencode /root/.bun WORKDIR /home/coder diff --git a/php/Dockerfile b/php/Dockerfile index 2cd7139..160cdeb 100644 --- a/php/Dockerfile +++ b/php/Dockerfile @@ -2,17 +2,16 @@ FROM codercom/enterprise-base:ubuntu ENV NODE_VERSION=24 ENV GLAB_VERSION=1.111.0 +ENV OPENCODE_VERSION=1.18.13 USER root RUN \ # REPOS #################################################################### apt-get update && \ - apt-get install -y --no-install-recommends curl wget software-properties-common gpg && \ + apt-get install -y --no-install-recommends curl wget gpg && \ # Node repo (needed for npm tools) curl -fsSL "https://deb.nodesource.com/setup_${NODE_VERSION}.x" | bash - && \ - # PHP repo - add-apt-repository -y ppa:ondrej/php && \ # GitHub CLI repo wget -qO /tmp/githubcli-archive-keyring.gpg https://cli.github.com/packages/githubcli-archive-keyring.gpg && \ mkdir -p -m 755 /etc/apt/keyrings && \ @@ -24,8 +23,9 @@ RUN \ apt-get dist-upgrade -y && \ apt-get install -y --no-install-recommends \ git jq ripgrep tmux nodejs \ - # PHP - php8.5-cli php8.5-common php8.5-curl php8.5-gd php8.5-imap php8.5-intl \ + # PHP (native Ubuntu packages; ondrej PPA has no release for this Ubuntu + # version and php8.5-imap no longer exists — imap was unbundled in 8.4) + php8.5-cli php8.5-common php8.5-curl php8.5-gd php8.5-intl \ php8.5-mailparse php8.5-mbstring php8.5-mysql php8.5-pgsql php8.5-phpdbg \ php8.5-readline php8.5-redis php8.5-soap php8.5-sqlite3 php8.5-xml \ php8.5-zip php8.5-bcmath php8.5-apcu php8.5-imagick \ @@ -52,14 +52,17 @@ RUN \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ - chmod +x /home/coder/.local/bin/claude 2>/dev/null || true && \ + (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - (curl -fsSL https://opencode.ai/install | bash || true) && \ + # Pinned version: avoids the rate-limited api.github.com "latest" lookup. + # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. + curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ - if [ -f /root/.opencode/bin/opencode ]; then cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode; fi && \ - chmod +x /home/coder/.opencode/bin/opencode 2>/dev/null || true && \ + cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ + chmod 0755 /home/coder/.opencode/bin/opencode && \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ + opencode --version && \ # NPM: CODEX, COPILOT ####################################################### npm install -g @openai/codex @github/copilot && \ # PI ######################################################################## @@ -68,11 +71,11 @@ RUN \ npm install -g agent-browser && \ runuser -u coder -- agent-browser install && \ # OWNERSHIP ################################################################ - chown -R coder:coder /home/coder/.local /home/coder/.opencode 2>/dev/null || true && \ + chown -R coder:coder /home/coder/.local /home/coder/.opencode && \ # CLEANUP ################################################################### apt-get clean -y && \ apt-get autoclean -y && \ - apt-get remove -y wget software-properties-common && \ + apt-get remove -y wget && \ apt-get autoremove -y && \ rm -rf /var/lib/apt/lists/* /var/lib/log/* /tmp/* /var/tmp/* \ /root/.npm /root/.cache /root/.local /root/.opencode diff --git a/python/Dockerfile b/python/Dockerfile index 2a83f00..e7b8ab6 100644 --- a/python/Dockerfile +++ b/python/Dockerfile @@ -2,6 +2,7 @@ FROM codercom/enterprise-base:ubuntu ENV NODE_VERSION=24 ENV GLAB_VERSION=1.111.0 +ENV OPENCODE_VERSION=1.18.13 USER root @@ -39,14 +40,17 @@ RUN \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ - chmod +x /home/coder/.local/bin/claude 2>/dev/null || true && \ + (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - (curl -fsSL https://opencode.ai/install | bash || true) && \ + # Pinned version: avoids the rate-limited api.github.com "latest" lookup. + # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. + curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ - if [ -f /root/.opencode/bin/opencode ]; then cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode; fi && \ - chmod +x /home/coder/.opencode/bin/opencode 2>/dev/null || true && \ + cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ + chmod 0755 /home/coder/.opencode/bin/opencode && \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ + opencode --version && \ # NPM: CODEX, COPILOT ####################################################### npm install -g @openai/codex @github/copilot && \ # PI ######################################################################## @@ -55,7 +59,7 @@ RUN \ npm install -g agent-browser && \ runuser -u coder -- agent-browser install && \ # OWNERSHIP ################################################################ - chown -R coder:coder /home/coder/.local /home/coder/.opencode 2>/dev/null || true && \ + chown -R coder:coder /home/coder/.local /home/coder/.opencode && \ # CLEANUP ################################################################### apt-get clean -y && \ apt-get autoclean -y && \ From 9dd85fa275e8c2fb831e53f37970527247ddea0c Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 6 Aug 2026 16:51:52 +0000 Subject: [PATCH 3/4] ci: retrigger after GitHub Actions runner outage Test (fx) and Test (golang) failed with 'Failed to resolve action download info: Service Unavailable' before any repo code ran. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01S9abShYK5RMmbeuZurGH3b From e01fd54cbf3d8092d696816173551683be7fbb4e Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 7 Aug 2026 10:55:29 +0000 Subject: [PATCH 4/4] Pin all tool versions via ENV, simplify comments Every installed tool now has an ENV *_VERSION pin: claude, deno, bun, composer, codex, copilot, pi, t3, pnpm, agent-browser (opencode, glab, go, node were already pinned). Conventions noted in CLAUDE.md. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01S9abShYK5RMmbeuZurGH3b --- CLAUDE.md | 10 ++++++++++ fx/Dockerfile | 32 ++++++++++++++++++++------------ golang/Dockerfile | 15 +++++++++------ nodejs/Dockerfile | 21 +++++++++++++-------- php/Dockerfile | 21 ++++++++++++--------- python/Dockerfile | 15 +++++++++------ 6 files changed, 73 insertions(+), 41 deletions(-) create mode 100644 CLAUDE.md diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..ccf22b3 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,10 @@ +# CLAUDE.md + +Coder Docker images (fx, php, nodejs, golang, python). + +## Conventions + +- Pin every tool version with an `ENV *_VERSION` variable in each Dockerfile. +- Keep Dockerfile comments very short and simple. +- No unparenthesized `|| true` in RUN chains — it can silently skip the rest of the build. +- Smoke tests live in the Makefile (`make test DOCKER_VARIANT=`). diff --git a/fx/Dockerfile b/fx/Dockerfile index 90fb996..98f825e 100644 --- a/fx/Dockerfile +++ b/fx/Dockerfile @@ -6,6 +6,16 @@ ENV NODE_VERSION=24 ENV GO_VERSION=1.26.5 ENV GLAB_VERSION=1.111.0 ENV OPENCODE_VERSION=1.18.13 +ENV CLAUDE_VERSION=2.1.224 +ENV DENO_VERSION=2.9.4 +ENV BUN_VERSION=1.3.14 +ENV COMPOSER_VERSION=2.10.2 +ENV CODEX_VERSION=0.147.0 +ENV COPILOT_VERSION=1.0.78 +ENV PI_VERSION=0.84.1 +ENV T3_VERSION=0.0.31 +ENV PNPM_VERSION=11.20.0 +ENV AGENT_BROWSER_VERSION=0.33.2 ENV GOROOT=/usr/local/go ENV GOPATH=/home/coder/go ENV PATH=$GOROOT/bin:$GOPATH/bin:$PATH @@ -42,8 +52,7 @@ RUN \ git jq ripgrep tmux \ # Node nodejs \ - # PHP (native Ubuntu packages; ondrej PPA has no release for this Ubuntu - # version and php8.5-imap no longer exists — imap was unbundled in 8.4) + # PHP php8.5-cli php8.5-common php8.5-curl php8.5-gd php8.5-intl \ php8.5-mailparse php8.5-mbstring php8.5-mysql php8.5-pgsql php8.5-phpdbg \ php8.5-readline php8.5-redis php8.5-soap php8.5-sqlite3 php8.5-xml \ @@ -71,38 +80,37 @@ RUN \ rm /tmp/go.tar.gz && \ mkdir -p /home/coder/go && \ # COMPOSER ################################################################## - curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer && \ + curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer --version=${COMPOSER_VERSION} && \ # GLAB (GitLab CLI) ######################################################## curl -fsSL "https://gitlab.com/gitlab-org/cli/-/releases/v${GLAB_VERSION}/downloads/glab_${GLAB_VERSION}_linux_$(dpkg --print-architecture).deb" -o /tmp/glab.deb && \ dpkg -i /tmp/glab.deb && \ rm -f /tmp/glab.deb && \ # DENO ###################################################################### - curl -fsSL https://deno.land/install.sh | sh && \ + curl -fsSL https://deno.land/install.sh | sh -s v${DENO_VERSION} && \ # BUN ####################################################################### - curl -fsSL https://bun.sh/install | bash && \ + curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" && \ # CLAUDE #################################################################### # Install into /usr/local/bin (image layer) so the binary survives the # persistent /home/coder volume that Coder mounts over the home dir at runtime. - (curl -fsSL https://claude.ai/install.sh | bash || true) && \ + (curl -fsSL https://claude.ai/install.sh | bash -s ${CLAUDE_VERSION} || true) && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /usr/local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /usr/local/bin/claude; fi && \ chmod 0755 /usr/local/bin/claude && \ # OPENCODE ################################################################## - # Pinned version: avoids the rate-limited api.github.com "latest" lookup. curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ cp /root/.opencode/bin/opencode /usr/local/bin/opencode && \ chmod 0755 /usr/local/bin/opencode && \ opencode --version && \ # NPM: CODEX, COPILOT ####################################################### - npm install -g @openai/codex @github/copilot && \ + npm install -g @openai/codex@${CODEX_VERSION} @github/copilot@${COPILOT_VERSION} && \ # PI ######################################################################## - npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ + npm install -g --ignore-scripts @earendil-works/pi-coding-agent@${PI_VERSION} && \ # T3CODE (browser GUI for coding agents) ################################### - npm install -g t3 && \ + npm install -g t3@${T3_VERSION} && \ # PNPM ###################################################################### - npm install -g pnpm && \ + npm install -g pnpm@${PNPM_VERSION} && \ # AGENT-BROWSER ############################################################## - npm install -g agent-browser && \ + npm install -g agent-browser@${AGENT_BROWSER_VERSION} && \ runuser -u coder -- agent-browser install && \ # PROFILE (DENO, BUN PATH) ################################################## echo '' >> /etc/profile && \ diff --git a/golang/Dockerfile b/golang/Dockerfile index 615848e..0c492dd 100644 --- a/golang/Dockerfile +++ b/golang/Dockerfile @@ -4,6 +4,11 @@ ENV NODE_VERSION=24 ENV GO_VERSION=1.26.5 ENV GLAB_VERSION=1.111.0 ENV OPENCODE_VERSION=1.18.13 +ENV CLAUDE_VERSION=2.1.224 +ENV CODEX_VERSION=0.147.0 +ENV COPILOT_VERSION=1.0.78 +ENV PI_VERSION=0.84.1 +ENV AGENT_BROWSER_VERSION=0.33.2 ENV GOROOT=/usr/local/go ENV GOPATH=/home/coder/go ENV PATH=$GOROOT/bin:$GOPATH/bin:$PATH @@ -44,15 +49,13 @@ RUN \ rm /tmp/go.tar.gz && \ mkdir -p /home/coder/go && \ # CLAUDE #################################################################### - (curl -fsSL https://claude.ai/install.sh | bash || true) && \ + (curl -fsSL https://claude.ai/install.sh | bash -s ${CLAUDE_VERSION} || true) && \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - # Pinned version: avoids the rate-limited api.github.com "latest" lookup. - # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ @@ -60,11 +63,11 @@ RUN \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ opencode --version && \ # NPM: CODEX, COPILOT ####################################################### - npm install -g @openai/codex @github/copilot && \ + npm install -g @openai/codex@${CODEX_VERSION} @github/copilot@${COPILOT_VERSION} && \ # PI ######################################################################## - npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ + npm install -g --ignore-scripts @earendil-works/pi-coding-agent@${PI_VERSION} && \ # AGENT-BROWSER ############################################################## - npm install -g agent-browser && \ + npm install -g agent-browser@${AGENT_BROWSER_VERSION} && \ runuser -u coder -- agent-browser install && \ # PROFILE ################################################################## echo '' >> /etc/profile && \ diff --git a/nodejs/Dockerfile b/nodejs/Dockerfile index cf59160..0322e2c 100644 --- a/nodejs/Dockerfile +++ b/nodejs/Dockerfile @@ -5,6 +5,13 @@ ENV BUN_INSTALL=/usr/local ENV NODE_VERSION=24 ENV GLAB_VERSION=1.111.0 ENV OPENCODE_VERSION=1.18.13 +ENV CLAUDE_VERSION=2.1.224 +ENV DENO_VERSION=2.9.4 +ENV BUN_VERSION=1.3.14 +ENV CODEX_VERSION=0.147.0 +ENV COPILOT_VERSION=1.0.78 +ENV PI_VERSION=0.84.1 +ENV AGENT_BROWSER_VERSION=0.33.2 USER root @@ -36,19 +43,17 @@ RUN \ dpkg -i /tmp/glab.deb && \ rm -f /tmp/glab.deb && \ # DENO ###################################################################### - curl -fsSL https://deno.land/install.sh | sh && \ + curl -fsSL https://deno.land/install.sh | sh -s v${DENO_VERSION} && \ # BUN ####################################################################### - curl -fsSL https://bun.sh/install | bash && \ + curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" && \ # CLAUDE #################################################################### - (curl -fsSL https://claude.ai/install.sh | bash || true) && \ + (curl -fsSL https://claude.ai/install.sh | bash -s ${CLAUDE_VERSION} || true) && \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - # Pinned version: avoids the rate-limited api.github.com "latest" lookup. - # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ @@ -56,11 +61,11 @@ RUN \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ opencode --version && \ # NPM: CODEX, COPILOT ####################################################### - npm install -g @openai/codex @github/copilot && \ + npm install -g @openai/codex@${CODEX_VERSION} @github/copilot@${COPILOT_VERSION} && \ # PI ######################################################################## - npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ + npm install -g --ignore-scripts @earendil-works/pi-coding-agent@${PI_VERSION} && \ # AGENT-BROWSER ############################################################## - npm install -g agent-browser && \ + npm install -g agent-browser@${AGENT_BROWSER_VERSION} && \ runuser -u coder -- agent-browser install && \ # PROFILE ################################################################## echo '' >> /etc/profile && \ diff --git a/php/Dockerfile b/php/Dockerfile index 160cdeb..2bda237 100644 --- a/php/Dockerfile +++ b/php/Dockerfile @@ -3,6 +3,12 @@ FROM codercom/enterprise-base:ubuntu ENV NODE_VERSION=24 ENV GLAB_VERSION=1.111.0 ENV OPENCODE_VERSION=1.18.13 +ENV CLAUDE_VERSION=2.1.224 +ENV COMPOSER_VERSION=2.10.2 +ENV CODEX_VERSION=0.147.0 +ENV COPILOT_VERSION=1.0.78 +ENV PI_VERSION=0.84.1 +ENV AGENT_BROWSER_VERSION=0.33.2 USER root @@ -23,8 +29,7 @@ RUN \ apt-get dist-upgrade -y && \ apt-get install -y --no-install-recommends \ git jq ripgrep tmux nodejs \ - # PHP (native Ubuntu packages; ondrej PPA has no release for this Ubuntu - # version and php8.5-imap no longer exists — imap was unbundled in 8.4) + # PHP php8.5-cli php8.5-common php8.5-curl php8.5-gd php8.5-intl \ php8.5-mailparse php8.5-mbstring php8.5-mysql php8.5-pgsql php8.5-phpdbg \ php8.5-readline php8.5-redis php8.5-soap php8.5-sqlite3 php8.5-xml \ @@ -42,21 +47,19 @@ RUN \ libatk1.0-0 libxrender1 libfontconfig1 libdbus-1-3 libxcb1 libxext6 libx11-6 && \ echo 'variables_order = "EGPCS"' > /etc/php/8.5/cli/conf.d/99-coder.ini && \ # COMPOSER ################################################################## - curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer && \ + curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer --version=${COMPOSER_VERSION} && \ # GLAB (GitLab CLI) ######################################################## curl -fsSL "https://gitlab.com/gitlab-org/cli/-/releases/v${GLAB_VERSION}/downloads/glab_${GLAB_VERSION}_linux_$(dpkg --print-architecture).deb" -o /tmp/glab.deb && \ dpkg -i /tmp/glab.deb && \ rm -f /tmp/glab.deb && \ # CLAUDE #################################################################### - (curl -fsSL https://claude.ai/install.sh | bash || true) && \ + (curl -fsSL https://claude.ai/install.sh | bash -s ${CLAUDE_VERSION} || true) && \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - # Pinned version: avoids the rate-limited api.github.com "latest" lookup. - # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ @@ -64,11 +67,11 @@ RUN \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ opencode --version && \ # NPM: CODEX, COPILOT ####################################################### - npm install -g @openai/codex @github/copilot && \ + npm install -g @openai/codex@${CODEX_VERSION} @github/copilot@${COPILOT_VERSION} && \ # PI ######################################################################## - npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ + npm install -g --ignore-scripts @earendil-works/pi-coding-agent@${PI_VERSION} && \ # AGENT-BROWSER ############################################################## - npm install -g agent-browser && \ + npm install -g agent-browser@${AGENT_BROWSER_VERSION} && \ runuser -u coder -- agent-browser install && \ # OWNERSHIP ################################################################ chown -R coder:coder /home/coder/.local /home/coder/.opencode && \ diff --git a/python/Dockerfile b/python/Dockerfile index e7b8ab6..f34ae51 100644 --- a/python/Dockerfile +++ b/python/Dockerfile @@ -3,6 +3,11 @@ FROM codercom/enterprise-base:ubuntu ENV NODE_VERSION=24 ENV GLAB_VERSION=1.111.0 ENV OPENCODE_VERSION=1.18.13 +ENV CLAUDE_VERSION=2.1.224 +ENV CODEX_VERSION=0.147.0 +ENV COPILOT_VERSION=1.0.78 +ENV PI_VERSION=0.84.1 +ENV AGENT_BROWSER_VERSION=0.33.2 USER root @@ -36,15 +41,13 @@ RUN \ dpkg -i /tmp/glab.deb && \ rm -f /tmp/glab.deb && \ # CLAUDE #################################################################### - (curl -fsSL https://claude.ai/install.sh | bash || true) && \ + (curl -fsSL https://claude.ai/install.sh | bash -s ${CLAUDE_VERSION} || true) && \ mkdir -p /home/coder/.local/bin && \ if [ -f /root/.local/bin/claude ]; then cp /root/.local/bin/claude /home/coder/.local/bin/claude; fi && \ if [ -f /root/bin/claude ]; then cp /root/bin/claude /home/coder/.local/bin/claude; fi && \ (chmod +x /home/coder/.local/bin/claude 2>/dev/null || true) && \ ln -sf /home/coder/.local/bin/claude /usr/local/bin/claude && \ # OPENCODE ################################################################## - # Pinned version: avoids the rate-limited api.github.com "latest" lookup. - # Installed into /home/coder/.opencode/bin so the coder user can self-upgrade. curl -fsSL https://opencode.ai/install | VERSION=${OPENCODE_VERSION} bash -s -- --no-modify-path && \ mkdir -p /home/coder/.opencode/bin && \ cp /root/.opencode/bin/opencode /home/coder/.opencode/bin/opencode && \ @@ -52,11 +55,11 @@ RUN \ ln -sf /home/coder/.opencode/bin/opencode /usr/local/bin/opencode && \ opencode --version && \ # NPM: CODEX, COPILOT ####################################################### - npm install -g @openai/codex @github/copilot && \ + npm install -g @openai/codex@${CODEX_VERSION} @github/copilot@${COPILOT_VERSION} && \ # PI ######################################################################## - npm install -g --ignore-scripts @earendil-works/pi-coding-agent && \ + npm install -g --ignore-scripts @earendil-works/pi-coding-agent@${PI_VERSION} && \ # AGENT-BROWSER ############################################################## - npm install -g agent-browser && \ + npm install -g agent-browser@${AGENT_BROWSER_VERSION} && \ runuser -u coder -- agent-browser install && \ # OWNERSHIP ################################################################ chown -R coder:coder /home/coder/.local /home/coder/.opencode && \