2022-09-26 13:31:27 -04:00
|
|
|
FROM casjaysdevdocker/alpine:latest as build
|
|
|
|
|
|
|
|
ARG LICENSE=WTFPL \
|
|
|
|
IMAGE_NAME=transmission \
|
|
|
|
TIMEZONE=America/New_York \
|
|
|
|
PORT=
|
|
|
|
|
|
|
|
ENV SHELL=/bin/bash \
|
|
|
|
TERM=xterm-256color \
|
|
|
|
HOSTNAME=${HOSTNAME:-casjaysdev-$IMAGE_NAME} \
|
|
|
|
TZ=$TIMEZONE
|
|
|
|
|
|
|
|
RUN mkdir -p /bin/ /config/ /data/ && \
|
|
|
|
rm -Rf /bin/.gitkeep /config/.gitkeep /data/.gitkeep && \
|
2022-09-27 09:48:06 -04:00
|
|
|
apk update -U --no-cache transmission-daemon
|
2022-09-26 13:31:27 -04:00
|
|
|
|
|
|
|
COPY ./bin/. /usr/local/bin/
|
2022-09-27 09:41:03 -04:00
|
|
|
COPY ./config/. /etc/
|
2022-09-26 13:31:27 -04:00
|
|
|
COPY ./data/. /data/
|
|
|
|
|
|
|
|
FROM scratch
|
|
|
|
ARG BUILD_DATE="$(date +'%Y-%m-%d %H:%M')"
|
|
|
|
|
|
|
|
LABEL org.label-schema.name="transmission" \
|
|
|
|
org.label-schema.description="Containerized version of transmission" \
|
|
|
|
org.label-schema.url="https://hub.docker.com/r/casjaysdevdocker/transmission" \
|
|
|
|
org.label-schema.vcs-url="https://github.com/casjaysdevdocker/transmission" \
|
|
|
|
org.label-schema.build-date=$BUILD_DATE \
|
|
|
|
org.label-schema.version=$BUILD_DATE \
|
|
|
|
org.label-schema.vcs-ref=$BUILD_DATE \
|
|
|
|
org.label-schema.license="$LICENSE" \
|
|
|
|
org.label-schema.vcs-type="Git" \
|
|
|
|
org.label-schema.schema-version="latest" \
|
|
|
|
org.label-schema.vendor="CasjaysDev" \
|
|
|
|
maintainer="CasjaysDev <docker-admin@casjaysdev.com>"
|
|
|
|
|
|
|
|
ENV SHELL="/bin/bash" \
|
|
|
|
TERM="xterm-256color" \
|
|
|
|
HOSTNAME="casjaysdev-transmission" \
|
|
|
|
TZ="${TZ:-America/New_York}"
|
|
|
|
|
|
|
|
WORKDIR /root
|
|
|
|
|
|
|
|
VOLUME ["/root","/config","/data"]
|
|
|
|
|
|
|
|
EXPOSE $PORT
|
|
|
|
|
|
|
|
COPY --from=build /. /
|
|
|
|
|
|
|
|
ENTRYPOINT [ "tini", "--" ]
|
|
|
|
HEALTHCHECK CMD [ "/usr/local/bin/entrypoint-transmission.sh", "healthcheck" ]
|
|
|
|
CMD [ "/usr/local/bin/entrypoint-transmission.sh" ]
|