added webapp image

This commit is contained in:
andreas
2023-02-15 21:12:00 +00:00
parent bf973bc94d
commit 49f6dcc3fb
3 changed files with 34 additions and 20 deletions

View File

@@ -1,26 +1,37 @@
# syntax=docker/dockerfile:1.4
FROM ubuntu:20.04
# install apt packages
RUN <<EOF
apt-get update -y
RUN <<EOF
export DEBIAN_FRONTEND=noninteractive
export TZ=Europe/Berlin
apt-get install -y tzdata z-push apache2 wget
apt-get autoclean
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* ~/.cache ~/.npm
apt-get update
apt-get install -y tzdata wget gnupg apache2
EOF
# install kopano webapp
RUN <<EOF
# 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
# install kopano-webapp
wget --no-verbose -P/tmp http://bldr/webapp-6.0.0.57.1049268-Ubuntu_20.04-all.tar.gz
tar xzf /tmp/webapp-6.0.0.57.1049268-Ubuntu_20.04-all.tar.gz
for F in ~/webapp-6.0.0.57.1049268-Ubuntu_20.04-all/*.deb; do dpkg --unpack --no-triggers $F; done
for F in webapp-6.0.0.57.1049268-Ubuntu_20.04-all/*.deb; do dpkg --unpack --no-triggers $F; done
apt-get install -f -y
apt-get clean
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* ~/.cache ~/.npm
rm -rf ~/webapp-6.0.0.57.1049268-Ubuntu_20.04-all
EOF
# RUN <<EOF
# apt-get autoclean
# rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* ~/.cache ~/.npm
# rm -rf webapp-6.0.0.57.1049268-Ubuntu_20.04-all
# 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
WORKDIR /root
RUN <<EOF
apt-get install -y libapache2-mod-php7.4
a2ensite kopano-webapp
# phpenmod kopano
# sed -i -e's/^;session.cookie_secure =/session.cookie_secure = false/' /etc/php/7.4/apache2/php.ini
sed -i -e's/define("SECURE_COOKIES", true);/define("SECURE_COOKIES", false);/' /etc/kopano/webapp/config.php
EOF
EXPOSE 80
VOLUME /var/lib/z-push
ENTRYPOINT ["/bin/bash"]
ENTRYPOINT ["/bin/bash"]