Fix opencode download: save to disk before extracting
Some checks failed
CI / lint-and-test (push) Successful in 35s
Deploy Production / deploy (push) Failing after 3m3s
CI / build (push) Failing after 3m29s

Piping curl directly to tar fails in CI when the download is chunked,
causing "not found in archive". Download to a temp file first.
Verified on linux/amd64.
This commit is contained in:
Julia McGhee
2026-03-21 23:15:00 +00:00
parent 033bb1f4e6
commit 325c88103f

View File

@@ -41,8 +41,10 @@ RUN apk add --no-cache git github-cli curl ca-certificates
# Agent CLIs (installed globally before dropping to non-root) # Agent CLIs (installed globally before dropping to non-root)
RUN npm install -g @anthropic-ai/claude-code @openai/codex RUN npm install -g @anthropic-ai/claude-code @openai/codex
RUN ARCH=$(uname -m | sed 's/x86_64/x64/;s/aarch64/arm64/') && \ RUN ARCH=$(uname -m | sed 's/x86_64/x64/;s/aarch64/arm64/') && \
curl -fsSL -L "https://github.com/anomalyco/opencode/releases/latest/download/opencode-linux-${ARCH}-musl.tar.gz" \ curl -fsSL -L -o /tmp/opencode.tar.gz "https://github.com/anomalyco/opencode/releases/latest/download/opencode-linux-${ARCH}-musl.tar.gz" && \
| tar xz -C /usr/local/bin opencode tar xzf /tmp/opencode.tar.gz -C /usr/local/bin && \
rm /tmp/opencode.tar.gz && \
opencode --version
# MCP servers: Gitea (Go binary from builder stage) # MCP servers: Gitea (Go binary from builder stage)
COPY --from=gitea-mcp-builder /usr/local/bin/gitea-mcp /usr/local/bin/gitea-mcp COPY --from=gitea-mcp-builder /usr/local/bin/gitea-mcp /usr/local/bin/gitea-mcp