OnlyOfficeCS-docker/Dockerfile

68 lines
3.3 KiB
Docker
Raw Normal View History

2019-01-21 12:34:44 +00:00
FROM ubuntu:18.04
2015-04-17 15:16:43 +00:00
2016-06-22 09:47:40 +00:00
ARG RELEASE_DATE="2016-06-21"
ARG RELEASE_DATE_SIGN=""
ARG VERSION="8.9.0.190"
ARG SOURCE_REPO_URL="deb http://static.teamlab.com.s3.amazonaws.com/repo/debian squeeze main"
2018-01-18 17:43:31 +00:00
ARG DEBIAN_FRONTEND=noninteractive
2016-06-22 09:47:40 +00:00
LABEL onlyoffice.community.release-date="${RELEASE_DATE}" \
onlyoffice.community.version="${VERSION}" \
maintainer="Ascensio System SIA <support@onlyoffice.com>" \
securitytxt="https://www.onlyoffice.com/.well-known/security.txt"
2016-06-22 09:47:40 +00:00
2019-01-24 15:10:42 +00:00
ENV LANG=en_US.UTF-8 \
LANGUAGE=en_US:en \
LC_ALL=en_US.UTF-8
2015-04-17 15:16:43 +00:00
2018-01-18 17:43:31 +00:00
RUN apt-get -y update && \
2019-05-14 16:11:45 +00:00
apt-get -yq install gnupg2 ca-certificates && \
2019-01-21 12:34:44 +00:00
apt-get install -yq sudo locales && \
addgroup --system --gid 107 onlyoffice && \
adduser -uid 104 --quiet --home /var/www/onlyoffice --system --gid 107 onlyoffice && \
addgroup --system --gid 104 elasticsearch && \
adduser -uid 103 --quiet --home /nonexistent --system --gid 104 elasticsearch && \
2018-01-18 17:43:31 +00:00
echo "${SOURCE_REPO_URL}" >> /etc/apt/sources.list && \
2020-01-30 13:47:10 +00:00
echo "deb https://download.mono-project.com/repo/ubuntu stable-bionic/snapshots/6.0 main" | tee /etc/apt/sources.list.d/mono-official.list && \
echo "deb http://download.onlyoffice.com/repo/mono/ubuntu bionic main" | tee /etc/apt/sources.list.d/mono-onlyoffice.list && \
2016-12-16 12:47:07 +00:00
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 && \
2015-04-17 15:16:43 +00:00
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \
locale-gen en_US.UTF-8 && \
2015-05-12 09:03:34 +00:00
apt-get -y update && \
2018-01-18 17:43:31 +00:00
apt-get install -yq software-properties-common wget curl cron rsyslog && \
2018-01-19 08:23:01 +00:00
wget http://nginx.org/keys/nginx_signing.key && \
apt-key add nginx_signing.key && \
2019-01-21 12:34:44 +00:00
echo "deb http://nginx.org/packages/mainline/ubuntu/ bionic nginx" >> /etc/apt/sources.list.d/nginx.list && \
echo "deb-src http://nginx.org/packages/mainline/ubuntu/ bionic nginx" >> /etc/apt/sources.list.d/nginx.list && \
2019-02-27 09:41:58 +00:00
apt-get install -yq openjdk-8-jre-headless && \
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add - && \
2018-01-18 17:43:31 +00:00
apt-get install -yq apt-transport-https && \
echo "deb https://artifacts.elastic.co/packages/6.x/apt stable main" | tee -a /etc/apt/sources.list.d/elastic-6.x.list && \
apt-get update && \
apt-get install -yq elasticsearch=6.5.0 && \
2017-04-14 15:19:25 +00:00
add-apt-repository -y ppa:certbot/certbot && \
2019-02-06 10:12:37 +00:00
add-apt-repository -y ppa:chris-lea/redis-server && \
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - && \
apt-get install -y nodejs && \
2015-05-12 09:03:34 +00:00
apt-get -y update && \
2019-05-15 12:04:11 +00:00
apt-get install -yq nginx gdb mono-complete ca-certificates-mono && \
2015-05-12 09:03:34 +00:00
echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d && \
apt-get install -yq dumb-init python-certbot-nginx htop nano dnsutils redis-server python3-pip multiarch-support iproute2 ffmpeg jq && \
apt-get install -yq mono-webserver-hyperfastcgi=0.4-7 && \
2018-03-22 09:23:45 +00:00
apt-get install -yq onlyoffice-communityserver && \
2015-04-17 15:16:43 +00:00
rm -rf /var/lib/apt/lists/*
COPY config /app/onlyoffice/config/
COPY assets /app/onlyoffice/assets/
COPY run-community-server.sh /app/onlyoffice/run-community-server.sh
2016-06-22 09:47:40 +00:00
RUN chmod -R 755 /app/onlyoffice/*.sh
2015-04-17 15:16:43 +00:00
2019-01-24 15:10:42 +00:00
VOLUME ["/var/log/onlyoffice", "/var/www/onlyoffice/Data", "/var/lib/mysql"]
2015-04-17 15:16:43 +00:00
2016-06-22 09:47:40 +00:00
EXPOSE 80 443 5222 3306 9865 9888 9866 9871 9882 5280
2017-07-06 16:12:54 +00:00
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
2017-02-07 16:46:34 +00:00
CMD ["/app/onlyoffice/run-community-server.sh"];