2023-02-27 06:22:39 +00:00
|
|
|
FROM alpine:3.17
|
|
|
|
|
|
|
|
ARG TARGETOS
|
|
|
|
ARG TARGETARCH
|
2023-02-28 03:47:56 +00:00
|
|
|
ARG USER=gorush
|
|
|
|
ENV HOME /home/$USER
|
2018-02-18 15:46:11 +00:00
|
|
|
|
|
|
|
LABEL maintainer="Bo-Yi Wu <appleboy.tw@gmail.com>" \
|
|
|
|
org.label-schema.name="Gorush" \
|
|
|
|
org.label-schema.vendor="Bo-Yi Wu" \
|
|
|
|
org.label-schema.schema-version="1.0"
|
|
|
|
|
2023-02-28 03:47:56 +00:00
|
|
|
# add new user
|
|
|
|
RUN adduser -D $USER
|
2022-06-30 13:48:47 +00:00
|
|
|
RUN apk add --no-cache ca-certificates mailcap && \
|
2023-02-27 06:22:39 +00:00
|
|
|
rm -rf /var/cache/apk/*
|
2022-06-30 13:48:47 +00:00
|
|
|
|
2023-02-27 06:22:39 +00:00
|
|
|
COPY release/${TARGETOS}/${TARGETARCH}/gorush /bin/
|
2019-03-16 03:37:01 +00:00
|
|
|
|
2023-02-28 03:47:56 +00:00
|
|
|
USER $USER
|
|
|
|
WORKDIR $HOME
|
|
|
|
|
2019-03-16 03:37:01 +00:00
|
|
|
EXPOSE 8088 9000
|
2021-07-13 02:28:34 +00:00
|
|
|
HEALTHCHECK --start-period=1s --interval=10s --timeout=5s \
|
2019-03-16 03:37:01 +00:00
|
|
|
CMD ["/bin/gorush", "--ping"]
|
2018-03-17 15:07:38 +00:00
|
|
|
|
2019-03-16 03:37:01 +00:00
|
|
|
ENTRYPOINT ["/bin/gorush"]
|