From 93a95d4be4d754a901ab42a8174ae0e725680a01 Mon Sep 17 00:00:00 2001 From: jwijenbergh Date: Tue, 9 Aug 2022 16:23:19 +0200 Subject: Docker: Run without a systemctl helper script --- ci/docker/eduvpn-server.docker | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'ci/docker/eduvpn-server.docker') diff --git a/ci/docker/eduvpn-server.docker b/ci/docker/eduvpn-server.docker index ab45a48..fd9891d 100644 --- a/ci/docker/eduvpn-server.docker +++ b/ci/docker/eduvpn-server.docker @@ -44,6 +44,9 @@ RUN cp resources/ssl.fedora.conf /etc/httpd/conf.d/ssl.conf RUN cp resources/localhost.fedora.conf /etc/httpd/conf.d/localhost.conf RUN cp resources/vpn.example.fedora.conf "/etc/httpd/conf.d/${WEB_FQDN}.conf" +# Otherwise we get: AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 172.20.0.6. Set the 'ServerName' directive globally to suppress this message +RUN echo "ServerName 127.0.0.1" >> /etc/httpd/conf/httpd.conf + RUN sed -i "s/vpn.example/${WEB_FQDN}/" "/etc/httpd/conf.d/${WEB_FQDN}.conf" RUN sed -i "s/vpn.example/${WEB_FQDN}/" "/etc/vpn-user-portal/config.php" @@ -64,15 +67,10 @@ COPY ./ci/docker/selfsigned/${WEB_FQDN}.crt /etc/pki/tls/certs/${WEB_FQDN}.crt WORKDIR /eduvpn/server ADD ci/docker/starteduvpn.sh /eduvpn/server ADD ci/docker/replaceexpiry.sh /eduvpn/server +ADD ci/docker/healthcheck.sh /eduvpn/server RUN chmod +x ./starteduvpn.sh RUN chmod +x ./replaceexpiry.sh - -# While we could mimic the systemd units ourselves, let's use a systemctl replacement script -# This makes it easier to update -RUN wget https://raw.githubusercontent.com/gdraheim/docker-systemctl-replacement/master/files/docker/systemctl3.py -O /bin/systemctl - -# make it executable -RUN chmod +x /bin/systemctl +RUN chmod +x ./healthcheck.sh CMD ["./starteduvpn.sh"] -- cgit v1.2.3