Add Docker (#58)

This commit is contained in:
Hossin Asaadi
2022-11-16 19:06:32 +03:30
committed by GitHub
parent bb419976a7
commit abc67e8bd4
4 changed files with 24 additions and 6 deletions

View File

@@ -5,10 +5,13 @@ RUN go build main.go
FROM debian:11-slim
LABEL org.opencontainers.image.authors="hossin.asaadi77@gmail.com"
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends -y ca-certificates \
&& apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
ENV TZ=Asia/Shanghai
WORKDIR /root
COPY --from=builder /root/main /root/x-ui
COPY bin/. /root/bin/.
COPY ./bin/. /root/bin/.
VOLUME [ "/etc/x-ui" ]
CMD [ "./x-ui" ]