1 Star 0 Fork 1

eetuuuu/graphjin

forked from jiadx1/graphjin 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Dockerfile 911 Bytes
一键复制 编辑 原始数据 按行查看 历史
Vikram Rangnekar 提交于 2021-12-18 16:52 +08:00 . Fix: retry only on db connection errors
# stage: 1
FROM node:latest as react-build
WORKDIR /web
COPY /serv/web/ ./
RUN yarn
RUN yarn build
# stage: 2
FROM golang:1.18beta1-bullseye as go-build
RUN apt-get -y update
RUN apt-get -y upgrade
RUN apt-get -y install build-essential git-all jq
RUN go install github.com/rafaelsq/wtc@latest
WORKDIR /app
COPY . /app
RUN mkdir -p /app/serv/web/build
COPY --from=react-build /web/build/ ./serv/web/build
RUN go mod download
RUN make build
# RUN echo "Compressing binary, will take a bit of time..." && \
# upx --ultra-brute -qq graphjin && \
# upx -t graphjin
# stage: 3
FROM alpine:latest
WORKDIR /
RUN apk add --no-cache tzdata
RUN apk add --no-cache libc6-compat
RUN mkdir -p /config
COPY --from=go-build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=go-build /app/graphjin .
RUN chmod +x /graphjin
#USER nobody
ENV GO_ENV production
ENTRYPOINT ["./graphjin"]
CMD ["serv"]
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/eetuuuu/graphjin.git
git@gitee.com:eetuuuu/graphjin.git
eetuuuu
graphjin
graphjin
master

搜索帮助