Update jitsi_admin_application_dockerfile.txt

This commit is contained in:
holzi1005 2024-11-17 00:26:04 +01:00
parent 44e675768e
commit d90439db47

View file

@ -19,8 +19,6 @@ USER root
RUN apk --no-cache add \
unzip \
sqlite \
cronie \
libcap \
php83-sqlite3 \
php83-pdo_sqlite \
php83-ldap \
@ -33,18 +31,17 @@ RUN apk --no-cache add \
RUN sed -i 's/^date.timezone=.*$/date.timezone="Europe\/Berlin"/' /etc/php83/conf.d/custom.ini
#RUN mkdir /etc/service/crond \
# && echo "#!/bin/sh -e" > /etc/service/crond/run \
# && echo "exec 2>&1 /usr/sbin/crond -f" >> /etc/service/crond/run \
# && chown -R nobody:nobody /etc/service/crond \
# && chmod -R +x /etc/service/crond \
RUN wget https://github.com/aptible/supercronic/releases/download/v0.2.33/supercronic-linux-amd64 -O /supercronic \
&& chmod +x /supercronic
RUN chown nobody:nobody /usr/sbin/crond \
&& setcap cap_setgid=ep /usr/sbin/crond \
&& setcap cap_setuid=ep /usr/sbin/crond
RUN wget https://github.com/aptible/supercronic/releases/download/v0.2.33/supercronic-linux-amd64 -O /supercronic \
&& chmod +x /supercronic
RUN wget https://git.h2-invent.com/Public-System-Design/Public-Helperscripts/raw/branch/main/distributed_cron.sh -O /distributed_cron.sh \
&& chmod +x /distributed_cron.sh
RUN mkdir /etc/service/cron \
&& echo "#!/bin/sh" > /etc/service/cron/run \
&& echo "exec 2>&1 /supercronic /var/crontab" >> /etc/service/cron/run \
&& chown -R nobody:nobody /etc/service/cron \
&& chmod -R +x /etc/service/cron
RUN mkdir /etc/service/symfony_messenger \
&& echo "#!/bin/sh -e" > /etc/service/symfony_messenger/run \
@ -52,13 +49,11 @@ RUN mkdir /etc/service/symfony_messenger \
&& chown -R nobody:nobody /etc/service/symfony_messenger \
&& chmod -R +x /etc/service/symfony_messenger
RUN echo "# Docker Cron Jobs" > /etc/crontabs/nobody \
&& echo "* * * * * curl http://localhost:8080/health/check" >> /etc/crontabs/nobody \
&& echo "* * * * * /bin/sh /distributed_cron.sh '${WEBDIR}/data/cron_lock' 'php ${WEBDIR}/bin/console cron:run' >/dev/null 2>&1" >> /etc/crontabs/nobody \
&& echo "" >> /etc/crontabs/nobody \
&& rm /etc/crontabs/root \
&& chown nobody:nobody /etc/crontabs/nobody \
&& chmod +x /etc/crontabs/nobody
RUN echo "# Docker Cron Jobs" > /var/crontab \
&& echo "SHELL=/bin/sh" >> /var/crontab \
&& echo "* * * * * /bin/sh /distributed_cron.sh '${WEBDIR}/data/cron_lock' 'php ${WEBDIR}/bin/console cron:run'" >> /var/crontab \
&& echo "" >> /var/crontab \
&& chown nobody:nobody /var/crontab \
RUN echo "#!/bin/sh" > /docker-entrypoint-init.d/02-theme.sh \
&& echo "if [ -d "${WEBDIR}/data/theme" ]" >> /docker-entrypoint-init.d/02-theme.sh \
@ -74,11 +69,6 @@ RUN echo "#!/bin/sh" > /docker-entrypoint-init.d/03-symfony.sh \
&& echo "php ${WEBDIR}/bin/console cache:clear" >> /docker-entrypoint-init.d/03-symfony.sh \
&& chmod +x /docker-entrypoint-init.d/03-symfony.sh
RUN echo "#!/bin/sh" > /docker-entrypoint-init.d/04-crond.sh \
&& echo "# Start crond as daemon via entry script" >> /docker-entrypoint-init.d/04-crond.sh \
&& echo "crond -b -l 8" >> /docker-entrypoint-init.d/04-crond.sh \
&& chmod +x /docker-entrypoint-init.d/04-crond.sh
RUN wget https://github.com/H2-invent/jitsi-admin/releases/download/${VERSION}/application.zip -O artifact.zip \
&& unzip artifact.zip -d ${WEBDIR} \
&& chown -R nobody public \