File size: 775 Bytes
8930510 c2f10cd e096766 c2f10cd | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | FROM eceasy/cli-proxy-api@sha256:c1a59b137cc6481074c2ebf912bb7031314f28eeff028f5cf3520349f9c846b8
USER root
# 安装必要依赖(基础镜像为 Debian)
RUN apt-get update && apt-get install -y --no-install-recommends bash && rm -rf /var/lib/apt/lists/*
WORKDIR /app
# 复制二进制文件
RUN cp /CLIProxyAPI/CLIProxyAPI ./cli-proxy-api && chmod +x ./cli-proxy-api
# 创建必要目录
RUN mkdir -p /tmp/.cli-proxy-api /tmp/logs /tmp/pg_cache/pgstore \
&& chmod -R 777 /tmp
# 复制配置文件
COPY config.yaml /app/config.yaml
# 关键:程序启动时需要此文件,否则报错
RUN cp /app/config.yaml /app/config.example.yaml
ENV TZ=Asia/Shanghai
EXPOSE 7860
# 直接运行,不使用 Nginx
CMD ["./cli-proxy-api", "--config", "/app/config.yaml"] |