34 lines
1.5 KiB
Docker
34 lines
1.5 KiB
Docker
# syntax=docker/dockerfile:1.4
|
|
FROM ubuntu:20.04
|
|
# install apt packages
|
|
RUN <<EOF
|
|
export DEBIAN_FRONTEND=noninteractive
|
|
export TZ=Europe/Berlin
|
|
apt-get update
|
|
apt-get install -y --no-install-recommends tzdata wget gnupg apache2 ca-certificates
|
|
update-ca-certificates
|
|
# install php7-mapi and dependencies
|
|
wget --no-verbose -P/tmp http://bldr/core-11.0.2.50.507cbae-Ubuntu_20.04-amd64.tar.gz
|
|
tar xzf /tmp/core-11.0.2.50.507cbae-Ubuntu_20.04-amd64.tar.gz
|
|
for F in core-11.0.2.50.507cbae-Ubuntu_20.04-amd64/*.deb; do dpkg --unpack --no-triggers $F; done
|
|
apt-get install -f -y --no-install-recommends
|
|
# install z-push
|
|
# wget --no-check-certificate -qO - https://download.kopano.io/zhub/z-push:/final/Ubuntu_20.04/Release.key | apt-key add -
|
|
wget -qO - https://download.kopano.io/zhub/z-push:/final/Ubuntu_20.04/Release.key | apt-key add -
|
|
echo "deb https://download.kopano.io/zhub/z-push:/final/Ubuntu_20.04/ /" >/etc/apt/sources.list.d/z-push.list
|
|
apt-get update
|
|
apt-get install -y z-push-kopano z-push-backend-kopano z-push-config-apache z-push-config-apache-autodiscover
|
|
apt-get install -f -y --no-install-recommends
|
|
# cleanup
|
|
apt-get autoclean
|
|
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* ~/.cache ~/.npm
|
|
rm -rf core-11.0.2.50.507cbae-Ubuntu_20.04-amd64
|
|
EOF
|
|
# use envsubst in entrypoint script to convert config templates to actual config files
|
|
COPY --chmod=0775 entrypoint.sh /entrypoint.sh
|
|
EXPOSE 80
|
|
VOLUME /etc/z-push
|
|
VOLUME /var/lib/z-push
|
|
ENTRYPOINT ["/entrypoint.sh"]
|
|
CMD ["apache2", "-DFOREGROUND"]
|