docker-gophernicus/Dockerfile
Josh 34dce6c3b1 Configuration via env & logging
Add an init entrypoint script to write out gophernicus xinetd
configuration using arguments sourced from the environment.

Default to apache-style logs and tail the output to stdout.
2020-05-26 22:28:47 -04:00

21 lines
626 B
Docker

FROM alpine:latest AS builder
ARG XINETD_VERSION=2.3.15.4
ARG VERSION=3.0.1
RUN apk add build-base autoconf automake libtool pkgconf git
RUN git clone -b ${XINETD_VERSION} https://github.com/openSUSE/xinetd.git
RUN cd xinetd && sh ./autogen.sh && ./configure && make
RUN git clone -b ${VERSION} https://github.com/gophernicus/gophernicus.git
RUN cd gophernicus && make
FROM alpine:latest
EXPOSE 70/tcp
VOLUME /var/gopher
COPY --from=builder /xinetd/xinetd /usr/sbin
COPY --from=builder /gophernicus/gophernicus /usr/sbin
COPY xinetd.conf /etc/xinetd.conf
COPY init.sh /init.sh
RUN mkdir -p /etc/xinetd.d/
CMD ["/init.sh"]