This commit is contained in:
Thilo Fromm 2022-10-31 20:00:34 +01:00 committed by GitHub
commit f77c0ee691
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 1 deletions

View file

@ -9,6 +9,10 @@ ENV LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_ALL=en_US.UTF-8 DEBIAN_FRONTEND=nonint
ARG ONLYOFFICE_VALUE=onlyoffice
RUN echo "# Enforce emptyfiles ulimit for rabbitmq to work around https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/491" \
| tee -a /etc/default/rabbitmq-server && \
echo "ulimit -n 65536" | tee -a /etc/default/rabbitmq-server
RUN echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d && \
apt-get -y update && \
apt-get -yq install wget apt-transport-https gnupg locales && \
@ -17,7 +21,7 @@ RUN echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d && \
chmod 644 /etc/apt/trusted.gpg.d/onlyoffice.gpg && \
locale-gen en_US.UTF-8 && \
echo ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true | debconf-set-selections && \
apt-get -yq install \
apt-get -yq -o Dpkg::Options::="--force-confold" install \
adduser \
apt-utils \
bomstrip \

View file

@ -574,6 +574,16 @@ if [ ${ONLYOFFICE_DATA_CONTAINER_HOST} = "localhost" ]; then
LOCAL_SERVICES+=("rabbitmq-server")
# allow Rabbitmq startup after container kill
rm -rf /var/run/rabbitmq
# Apply user-defined emptyfiles limit if set.
# See https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/491.
if [ -n "${RABBITMQ_EMPTYFILES_LIMIT:-}" ]; then
echo "Applying custom emptyfiles limit"
{
head -n -1 /etc/default/rabbitmq-server
echo "ulimit -n ${RABBITMQ_EMPTYFILES_LIMIT}"
} | tee /etc/default/rabbitmq-server
fi
fi
if [ ${REDIS_ENABLED} = "true" ]; then