This repository was archived by the owner on Dec 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 70
/
Copy pathsogo
53 lines (45 loc) · 1.84 KB
/
sogo
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#
# This file is managed by iRedMail Team <[email protected]> with Ansible,
# please do __NOT__ modify it manually.
#
FROM ubuntu:focal
MAINTAINER Zhang Huangbin <[email protected]>
# SOGo uses port `20000` by default.
EXPOSE 20000
ENV DEBIAN_FRONTEND noninteractive
ENV LC_ALL C
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE yes
ARG SOGO_MIRROR_SITE=https://packages.inverse.ca/SOGo/nightly/5/ubuntu/
ARG ENTRYPOINTS_DIR=/docker/entrypoints
# Create temporary file /usr/share/doc/sogo/test.sh to avoid an error in the
# post-install script of SOGo package.
RUN apt-get update && apt-get upgrade -y && apt-get install -y --no-install-recommends apt-transport-https \
apt-utils \
ca-certificates \
supervisor \
mariadb-client \
cron \
gnupg2 \
&& perl -pi -e \
's#http://archive.ubuntu.com/ubuntu/#[trusted=yes] http://archive.ubuntu.com/ubuntu/#g' \
/etc/apt/sources.list \
&& perl -pi -e \
's#http://security.ubuntu.com/ubuntu/#[trusted=yes] http://archive.ubuntu.com/ubuntu/#g' \
/etc/apt/sources.list \
&& apt-key adv --keyserver keyserver.ubuntu.com --recv-key 0x810273C4 \
&& echo "deb ${SOGO_MIRROR_SITE} focal focal" > /etc/apt/sources.list.d/sogo-nightly.list \
&& apt-get update \
&& mkdir -p /usr/share/doc/sogo/ \
&& touch /usr/share/doc/sogo/test.sh \
&& apt-get -y install sogo sogo-activesync memcached \
&& rm -f /usr/share/doc/sogo/test.sh \
&& apt-get clean && apt-get autoclean && rm -rf /var/lib/apt/lists/*
RUN mkdir -p ${ENTRYPOINTS_DIR}
COPY ./entrypoints/functions.sh ${ENTRYPOINTS_DIR}/
COPY ./settings.conf ${ENTRYPOINTS_DIR}/
# Copy config files.
# COPY config/sogo/. /
COPY config/etc/supervisor /etc/
COPY ./entrypoints/sogo.sh /entrypoint.sh
ENTRYPOINT ["/bin/bash", "/entrypoint.sh"]
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/supervisord.conf"]