############################################################ # Dockerfile to build default Habisreutinger CONTENTSERV environment # Based on Ubuntu ############################################################ FROM ubuntu:xenial ENV DEBIAN_FRONTEND noninteractive ENV APACHE_RUN_USER www-data ENV APACHE_RUN_GROUP www-data ENV APACHE_LOG_DIR /var/log/apache2 ENV TERM=xterm ############### # install utils ############### RUN apt-get update && apt-get -y install vim htop software-properties-common python-software-properties ##################### #add additional repos ##################### RUN apt-get install -y language-pack-en-base && \ export LC_ALL=en_US.UTF-8 && \ export LANG=en_US.UTF-8 && \ apt-get install -y software-properties-common && \ add-apt-repository ppa:ondrej/php && add-apt-repository ppa:jonathonf/ffmpeg-3 #&& add-apt-repository ppa:mc3man/xerus-media ######## #install ######## RUN apt-get update && apt-get -y --force-yes upgrade && \ apt-get -y --force-yes install apache2 libapache2-mod-php5.6 \ php5.6-mysql php5.6-curl php5.6-gd php5.6-ldap php5.6-xsl php5.6-mbstring php5.6-soap php5.6-zip \ curl ghostscript zip unzip barcode libimage-exiftool-perl wget \ supervisor msmtp vim && \ apt-get clean RUN apt-get install -y openjdk-8-jre openjdk-8-jre-headless RUN apt-get -y --force-yes install build-essential checkinstall libx11-dev libxext-dev \ zlib1g-dev libpng12-dev libjpeg-dev libfreetype6-dev libxml2-dev aspell subversion poppler-utils ffmpeg libav-tools x264 x265 RUN sed -i 's/# deb-src/deb-src/' /etc/apt/sources.list RUN apt-get update && apt-get -y install libtiff5-dev && apt-get -y build-dep imagemagick RUN cd /opt && wget "https://launchpad.net/imagemagick/main/6.9.4-9/+download/ImageMagick-6.9.4-9.tar.gz" && tar xvfz ImageMagick-6.9.4-9.tar.gz && \ cd ImageMagick-6.9.4-9/ && ./configure -q && checkinstall && dpkg -i /opt/ImageMagick-6.9.4-9/imagemagick-6.9.4_9-1_amd64.deb && \ ln -s /opt/ImageMagick-6.9.4-9/utilities/convert /usr/bin/convert && \ ln -s /opt/ImageMagick-6.9.4-9/utilities/mogrify /usr/bin/ && \ ln -s /opt/ImageMagick-6.9.4-9/utilities/identify /usr/bin/ && ldconfig /usr/local/lib ########### # configure ########### ADD cs-php.ini /etc/php/5.6/mods-available/ ADD cs-apache.conf /etc/apache2/conf-available/ ADD security.conf /etc/apache2/conf-available/ RUN \ /usr/sbin/phpenmod cs-php && \ /usr/sbin/a2enconf cs-apache && \ /usr/sbin/a2enmod rewrite deflate expires cgi #/usr/sbin/a2dismod 'mpm_*' && \ #mpm_prefork COPY etc /usr/local/etc COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf RUN \ chmod 600 /usr/local/etc/msmtprc/msmtprc && \ chown www-data:www-data /usr/local/etc/msmtprc/msmtprc EXPOSE 80 20 21 VOLUME ["/var/www/html/"] CMD /usr/bin/supervisord -c /etc/supervisor/supervisord.conf