From 63da4cb3d258222ff1b11052951c7e5d7ca8e02c Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Tue, 2 Jul 2019 11:14:07 +0200 Subject: Upgrade to 2019.07 This patch upgrade LAVA to 2019.07 via their official docker images. Along with the change of the baseimage from our lava-xx-base to official 2019.07, some minor changes are needed: - Activate the en_US.UTF-8 locale needed for postgresql - chown to lavaserver all copied device-types - Fix the start scripts for using the official entrypoints --- lava-master/Dockerfile | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'lava-master/Dockerfile') diff --git a/lava-master/Dockerfile b/lava-master/Dockerfile index 80da8fb..625ebf1 100644 --- a/lava-master/Dockerfile +++ b/lava-master/Dockerfile @@ -1,4 +1,6 @@ -FROM baylibre/lava-master-base:2019.03_stretch +FROM lavasoftware/lava-server:2019.07 + +RUN apt-get update && apt-get -y install sudo lava-coordinator git COPY backup /root/backup/ @@ -15,8 +17,7 @@ COPY device-types/ /root/device-types/ COPY users/ /root/lava-users/ COPY groups/ /root/lava-groups/ COPY tokens/ /root/lava-callback-tokens/ -COPY scripts/setup.sh / -COPY scripts/start.sh / +COPY entrypoint.d/*sh /root/entrypoint.d/ COPY settings.conf /etc/lava-server/ @@ -33,9 +34,18 @@ COPY zmq_auth/ /etc/lava-dispatcher/certificates.d/ COPY lava_http_fqdn /root/ COPY env/ /etc/lava-server/dispatcher.d/ +RUN chown -R lavaserver:lavaserver /etc/lava-server/dispatcher.d/ COPY apache2/ /etc/apache2/ +# Fixes 'postgresql ERROR: invalid locale name: "en_US.UTF-8"' when restoring a backup +RUN echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && locale-gen en_US.UTF-8 + +# TODO: send this fix to upstream +RUN sed -i 's,find /root/entrypoint.d/ -type f,find /root/entrypoint.d/ -type f | sort,' /root/entrypoint.sh +# TODO: send this fix to upstream +RUN sed -i 's,pidfile =.*,pidfile = "/run/lava-coordinator/lava-coordinator.pid",' /usr/bin/lava-coordinator + EXPOSE 3079 5555 5556 -CMD /start.sh && while [ true ];do sleep 365d; done +CMD /root/entrypoint.sh && while [ true ];do sleep 365d; done -- cgit 1.2.3-korg