1
Orenoid 16 天前
根据文档你需要自己构建一个 Docker 镜像,就是 [从 answer 基础镜像构建包含插件的版本] 这一部分,把那个示例的 Dockerfile 复制出来,把里面 RUN answer build 的 --with 参数列表替换成你想安装的插件,然后本地构建自己的镜像,然后用这个镜像去运行容器。
|
2
xiaohantx OP @Orenoid
我直接用这一段 FROM apache/answer as answer-builder FROM golang:1.22-alpine AS golang-builder COPY --from=answer-builder /usr/bin/answer /usr/bin/answer RUN apk --no-cache add \ build-base git bash nodejs npm go && \ npm install -g [email protected] RUN answer build \ --with github.com/apache/incubator-answer-plugins/connector-basic \ --with github.com/apache/incubator-answer-plugins/storage-s3 \ --with github.com/apache/incubator-answer-plugins/search-elasticsearch \ --output /usr/bin/new_answer FROM alpine LABEL maintainer="[email protected]" ARG TIMEZONE ENV TIMEZONE=${TIMEZONE:-"Asia/Shanghai"} RUN apk update \ && apk --no-cache add \ bash \ ca-certificates \ curl \ dumb-init \ gettext \ openssh \ sqlite \ gnupg \ tzdata \ && ln -sf /usr/share/zoneinfo/${TIMEZONE} /etc/localtime \ && echo "${TIMEZONE}" > /etc/timezone COPY --from=golang-builder /usr/bin/new_answer /usr/bin/answer COPY --from=answer-builder /data /data COPY --from=answer-builder /entrypoint.sh /entrypoint.sh RUN chmod 755 /entrypoint.sh VOLUME /data EXPOSE 80 ENTRYPOINT ["/entrypoint.sh"] 构建除了三个镜像= = |
3
xiaohantx OP @Orenoid 二进制构建的好像也是超时,./answer build --with github.com/apache/incubator-answer-plugins/connector-github
|