更新 Dockerfile,添加 bun-bin 镜像并复制 bun

This commit is contained in:
2026-05-11 18:32:58 +08:00
parent 0dcb04ee89
commit 319b3c8ea5
+4 -2
View File
@@ -1,3 +1,5 @@
FROM oven/bun:1 AS bun-bin
FROM smanx/opencode:latest AS base
USER root
ARG UBUNTU_APT_MIRROR=mirrors.aliyun.com
@@ -17,8 +19,6 @@ RUN sed -i "s|http://archive.ubuntu.com|https://${UBUNTU_APT_MIRROR}|g; s|http:/
python3 \
python3-venv && \
curl -LsSf https://astral.sh/uv/install.sh | sh && \
curl -fsSL https://bun.sh/install | bash && \
ln -s /root/.bun/bin/bun /usr/local/bin/bun && \
ln -s /root/.local/bin/uv /usr/local/bin/uv && \
ln -sf /usr/bin/python3 /usr/local/bin/python && \
mkdir -p /root/.config/pip && \
@@ -38,6 +38,8 @@ RUN sed -i "s|http://archive.ubuntu.com|https://${UBUNTU_APT_MIRROR}|g; s|http:/
pytest && \
rm -rf /var/lib/apt/lists/*
COPY --from=bun-bin /usr/local/bin/bun /usr/local/bin/bun
FROM base AS deps
WORKDIR /app