mirror of
https://github.com/eryajf/chatgpt-dingtalk.git
synced 2026-04-22 23:47:15 +08:00
25 lines
497 B
Docker
25 lines
497 B
Docker
FROM golang:1.18.10-alpine3.16 AS builder
|
|
|
|
# ENV GOPROXY https://goproxy.io
|
|
|
|
RUN mkdir /app
|
|
ADD . /app/
|
|
WORKDIR /app
|
|
RUN go build -o chatgpt-dingtalk .
|
|
|
|
FROM alpine:3.16
|
|
|
|
ARG TZ="Asia/Shanghai"
|
|
|
|
ENV TZ ${TZ}
|
|
|
|
RUN mkdir /app && apk upgrade \
|
|
&& apk add bash tzdata \
|
|
&& ln -sf /usr/share/zoneinfo/${TZ} /etc/localtime \
|
|
&& echo ${TZ} > /etc/timezone
|
|
|
|
WORKDIR /app
|
|
COPY --from=builder /app/ .
|
|
RUN chmod +x chatgpt-dingtalk && cp config.example.yml config.yml
|
|
|
|
CMD ./chatgpt-dingtalk |