Difference between revisions of "Dockerfile.isoweb"
From Cactus Howto
Jump to navigationJump to searchLine 8: | Line 8: | ||
RUN a2enmod ssl |
RUN a2enmod ssl |
||
RUN a2enmod php5 |
RUN a2enmod php5 |
||
⚫ | RUN sed -i.orig -e "s/^memory_limit\s*=.*/memory_limit = 200M/" -e "s/^max_execution_time\s*=.*/max_execution_time = 900/" -e "s/^default_charset\s*=.*/default_charset = \"utf\-8\"/" -e "s|^include_path\s*=.*|include_path = \"/usr/share/php:/usr/share/lib/php:/web/include:/etc:/web/htdocs/inctxt:/web/htdocs/hilfe\"|" -e "s|^doc_root\s*=.*|doc_root = /web|" -e "s/^sql\.safe_mode\s*=.*/sql.safe_mode = On/" -e "s/^expose_php\s*=.*/expose_php = Off/" -e "s/^display_errors\s*=.*/display_errors = Off/" -e "s/^display_startup_errors\s*=.*/display_startup_errors = Off/" -e "s/^error_log\s*=.*/error_log = syslog/" -e "s/^log_errors_max_len\s*=.*/log_errors_max_len = 0/" -e "s/^pgsql\.log_notice\s*=.*/pgsql.log_notice = 1/" -e "s|^session\.save_path\s*=.*|session.save_path = /var/itsecorg/session|" -e "s/^session\.gc_maxlifetime\s*=.*/session\.gc_maxlifetime = 14400/" /etc/php5/apache2/php.ini /etc/php5/cli/php.ini |
||
# Update the PHP.ini file, enable <? ?> tags and quieten logging. |
|||
⚫ | |||
ENV APACHE_RUN_USER www-data |
ENV APACHE_RUN_USER www-data |
Revision as of 13:59, 21 December 2014
FROM ubuntu:14.04.1 MAINTAINER itsecorg@cactus.de RUN DEBIAN_FRONTEND=noninteractive apt-get update && \ DEBIAN_FRONTEND=noninteractive apt-get install -y apache2 libapache2-mod-php5 php5-pgsql php-pear sharutils openssl ssl-cert && \ DEBIAN_FRONTEND=noninteractive apt-get clean && rm -rf /var/lib/apt/lists/* RUN a2enmod ssl RUN a2enmod php5 RUN sed -i.orig -e "s/^memory_limit\s*=.*/memory_limit = 200M/" -e "s/^max_execution_time\s*=.*/max_execution_time = 900/" -e "s/^default_charset\s*=.*/default_charset = \"utf\-8\"/" -e "s|^include_path\s*=.*|include_path = \"/usr/share/php:/usr/share/lib/php:/web/include:/etc:/web/htdocs/inctxt:/web/htdocs/hilfe\"|" -e "s|^doc_root\s*=.*|doc_root = /web|" -e "s/^sql\.safe_mode\s*=.*/sql.safe_mode = On/" -e "s/^expose_php\s*=.*/expose_php = Off/" -e "s/^display_errors\s*=.*/display_errors = Off/" -e "s/^display_startup_errors\s*=.*/display_startup_errors = Off/" -e "s/^error_log\s*=.*/error_log = syslog/" -e "s/^log_errors_max_len\s*=.*/log_errors_max_len = 0/" -e "s/^pgsql\.log_notice\s*=.*/pgsql.log_notice = 1/" -e "s|^session\.save_path\s*=.*|session.save_path = /var/itsecorg/session|" -e "s/^session\.gc_maxlifetime\s*=.*/session\.gc_maxlifetime = 14400/" /etc/php5/apache2/php.ini /etc/php5/cli/php.ini ENV APACHE_RUN_USER www-data ENV APACHE_RUN_GROUP www-data ENV APACHE_LOG_DIR /var/log/apache2 ENV APACHE_LOCK_DIR /var/lock/apache2 ENV APACHE_PID_FILE /var/run/apache2.pid # Copy site into place. ADD web /usr/share/itsecorg/web ADD configure_apache2.sh / ADD etc/httpd.conf /etc/apache2/sites-enabled/000-default.conf COPY etc/iso.conf /etc/ COPY etc/gui.conf /etc/ RUN sh /configure_apache2.sh EXPOSE 443 # Add VOLUMEs to allow backup of config, logs and databases VOLUME ["/etc/apache2", "/var/log/apache2", "/var/lib/apache2"] CMD ["/usr/sbin/apache2", "-D", "FOREGROUND"]