gemini-agate-image/Dockerfile

38 lines
1.1 KiB
Docker
Raw Normal View History

2022-10-06 19:57:53 +00:00
FROM golang:alpine as build_gmnitohtml
ENV GMNITOHTML_VER 0.1.2
RUN apk add make
RUN wget -O /tmp/gmnitohtml.tar.gz https://git.sr.ht/~adnano/gmnitohtml/archive/${GMNITOHTML_VER}.tar.gz \
&& tar -xvzf /tmp/gmnitohtml.tar.gz && cd gmnitohtml-${GMNITOHTML_VER} \
2022-10-06 20:20:58 +00:00
&& make gmnitohtml && cp ./gmnitohtml /usr/local/bin/gmnitohtml
2022-10-06 19:57:53 +00:00
2023-04-20 11:23:55 +00:00
FROM alpine:3.17 as build_agate
2021-02-20 20:47:59 +00:00
2023-04-20 11:23:55 +00:00
ENV AGATE_VER 3.3.0
2021-02-20 20:47:59 +00:00
2022-09-18 12:54:50 +00:00
RUN apk --no-cache add cargo
RUN cargo install agate --version ${AGATE_VER}
2022-10-06 19:57:53 +00:00
2023-04-20 11:23:55 +00:00
FROM alpine:3.17
2021-02-20 20:47:59 +00:00
ENV GEMINI_DOMAIN example.com
2023-04-20 11:23:55 +00:00
ENV GEMINI_GIT_REPO https://git.valvin.fr/valvin/gemini-agate-image.git
2021-02-20 20:47:59 +00:00
ENV GEMINI_GIT_PATH /app/data
ENV GEMINI_CONTENT_FOLDER content
ENV GEMINI_CERT_PATH /certs
ENV GEMINI_LANG fr-FR
2022-09-18 12:54:50 +00:00
ENV GEMINI_PORT 1965
ENV GEMINI_KILN_BUILD no
2022-09-18 12:54:50 +00:00
ENV GEMINI_KILN_SRC .
2021-02-20 20:47:59 +00:00
2022-09-18 12:54:50 +00:00
RUN apk --no-cache add openssl libgcc git kiln
2021-02-20 20:47:59 +00:00
RUN mkdir /app
2022-10-06 19:57:53 +00:00
COPY --from=build_agate /root/.cargo/bin/agate /app/agate
2022-10-06 20:20:58 +00:00
COPY --from=build_gmnitohtml /usr/local/bin/gmnitohtml /usr/local/bin/gmnitohtml
2021-02-20 20:47:59 +00:00
COPY entrypoint.sh /app/entrypoint.sh
EXPOSE 1965/tcp
ENTRYPOINT ["/app/entrypoint.sh"]
CMD ["run"]