From 43c9507c9ed37d03443d7baa65cd0d631e855ba1 Mon Sep 17 00:00:00 2001 From: Sam Bagheri Date: Thu, 3 Aug 2023 10:18:02 +0200 Subject: [PATCH] Cleaning up Dockerfile - changing transcripts path --- jigasi/Dockerfile | 26 ++++++++----------- .../defaults/sip-communicator.properties | 2 +- jigasi/rootfs/etc/services.d/jigasi/run | 2 +- 3 files changed, 13 insertions(+), 17 deletions(-) diff --git a/jigasi/Dockerfile b/jigasi/Dockerfile index 1e7014d24c..2db967bada 100644 --- a/jigasi/Dockerfile +++ b/jigasi/Dockerfile @@ -16,21 +16,17 @@ RUN apt-dpkg-wrap apt-get update && \ COPY --chown=noroot:noroot rootfs/ / -RUN mkdir /config -RUN mkdir -pm777 /tmp/transcripts - -RUN chown -R noroot:noroot /etc/cont-init.d -RUN chown -R noroot:noroot /etc/services.d -RUN chown -R noroot:noroot /tmp -RUN chown -R noroot:noroot /run -RUN chown -R noroot:noroot /config -RUN chown -R noroot:noroot /var -RUN chown -R noroot:noroot /usr/share -RUN chown -R noroot:noroot /defaults -RUN chmod +x /etc/cont-init.d/* -RUN chmod +x /etc/services.d/jigasi/* -RUN chmod +x /usr/share/jigasi/jigasi.sh +RUN chown -R noroot:noroot /etc/cont-init.d && \ + chown -R noroot:noroot /etc/services.d && \ + chown -R noroot:noroot /usr/share && \ + chown -R noroot:noroot /defaults && \ + mkdir -pm777 /config/transcripts && \ + mkdir -p /config && chown -R noroot:noroot /config + +RUN chmod +x /etc/cont-init.d/* && \ + chmod +x /etc/services.d/jigasi/* && \ + chmod +x /usr/share/jigasi/jigasi.sh USER noroot -VOLUME ["/config", "/tmp/transcripts"] +VOLUME /config diff --git a/jigasi/rootfs/defaults/sip-communicator.properties b/jigasi/rootfs/defaults/sip-communicator.properties index a13e49bc97..719c2fbd21 100644 --- a/jigasi/rootfs/defaults/sip-communicator.properties +++ b/jigasi/rootfs/defaults/sip-communicator.properties @@ -160,7 +160,7 @@ net.java.sip.communicator.service.gui.ALWAYS_TRUST_MODE_ENABLED=true # Transcription config org.jitsi.jigasi.ENABLE_TRANSCRIPTION=true org.jitsi.jigasi.transcription.ENABLE_TRANSLATION=true -org.jitsi.jigasi.transcription.DIRECTORY=/tmp/transcripts +org.jitsi.jigasi.transcription.DIRECTORY=/config/transcripts org.jitsi.jigasi.transcription.BASE_URL={{ .Env.PUBLIC_URL }}/transcripts org.jitsi.jigasi.transcription.jetty.port=-1 org.jitsi.jigasi.transcription.ADVERTISE_URL={{ .Env.JIGASI_TRANSCRIBER_ADVERTISE_URL | default "false"}} diff --git a/jigasi/rootfs/etc/services.d/jigasi/run b/jigasi/rootfs/etc/services.d/jigasi/run index c93367987c..2e2bca0a88 100644 --- a/jigasi/rootfs/etc/services.d/jigasi/run +++ b/jigasi/rootfs/etc/services.d/jigasi/run @@ -5,4 +5,4 @@ JAVA_SYS_PROPS="-Djava.util.logging.config.file=/config/logging.properties" DAEMON=/usr/share/jigasi/jigasi.sh DAEMON_OPTS="--nocomponent=true --configdir=/ --configdirname=config --min-port=${JIGASI_PORT_MIN:-20000} --max-port=${JIGASI_PORT_MAX:-20050}" -exec s6-setuidgid /bin/bash -c "JAVA_SYS_PROPS=\"$JAVA_SYS_PROPS\" exec $DAEMON $DAEMON_OPTS" +exec /bin/bash -c "JAVA_SYS_PROPS=\"$JAVA_SYS_PROPS\" exec $DAEMON $DAEMON_OPTS"