blob: b7e5762941e43db73bf188a2f1c586cc7d5d2023 (
plain)
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
|
FROM opensuse:42.3
MAINTAINER Suren A. Chilingaryan <csa@suren.me>
# Useful system applications
RUN zypper -n in glibc-locale mc bzr git openssh telnet curl python-pycurl
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
# Installation of ADEI & dependencies
RUN zypper ar http://download.opensuse.org/repositories/home:/csa7fff:/adei/openSUSE_Leap_42.3/home:csa7fff:adei.repo && \
zypper ar http://download.opensuse.org/repositories/server:/php:/extensions/openSUSE_Leap_42.3/server:php:extensions.repo && \
zypper ar http://download.opensuse.org/repositories/devel:languages:python/openSUSE_Tumbleweed/devel:languages:python.repo && \
zypper --gpg-auto-import-keys ref -s && \
zypper -n in supervisor procmail alpine which w3m && \
zypper -n in perl perl-DateTime-Format-Strptime mailx && \
zypper -n in make java && \
zypper -n in adei adei-config-default adei-req-mssql adei-webroot php-pecl-rrd && \
zypper -n in bzr-webdav
VOLUME /var/log/apache2
VOLUME /var/spool/mail
VOLUME /adei/src
VOLUME /adei/cfg
VOLUME /adei/tmp
VOLUME /adei/sys
COPY supervisor/supervisord.conf /etc/supervisord.conf
# Apply configuration changes
COPY configs /opt/configs
COPY scripts /opt/scripts
RUN /opt/scripts/configure.sh
# Replace packaged ADEI with repository version
RUN rm -rf /srv/www/htdocs/adei && \
ln -s /adei/src /srv/www/htdocs/adei
# Modify for non-priviledged mode
RUN ln -sf /etc/mime.types /etc/apache2/mime.types && \
find /etc/apache2 -type d -exec chmod +rx '{}' \; && \
chmod -R +r /etc/apache2 && \
chmod a+w /etc/apache2/listen.conf && \
chmod a+w /etc/apache2/server-tuning.conf && \
mkdir -p /etc/apache2/sysconfig.d && \
chmod a+rwx /etc/apache2/sysconfig.d && \
sed -i'' -re 's@/var/run@/tmp@' /usr/sbin/start_apache2 && \
chmod +x /usr/sbin/start_apache2
# Ugly python needs to resolve user name
RUN chmod g=u /etc/passwd
ENV MYSQL_SERVER adei-mysql
ENV MYSQL_PORT 3306
ENV MYSQL_USER adei
ENV MYSQL_PASSWORD adei
ENV MYSQL_DATABASE adei
ENV ADEI_REVISION last:1
ENV ADEI_PARALLEL sources
ENV ADEI_SETUP all
ENV ADEI_ENABLED_SETUPS autogen logs
ENV ADEI_PORTS 80
ENV APACHE_SERVERS 0
COPY *-entrypoint.sh /
ENTRYPOINT ["/docker-entrypoint.sh"]
EXPOSE 80
CMD /usr/bin/supervisord -c /etc/supervisord.conf
|