diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..bec4676a0497443645c1cd37704a1daa58f11ca7 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,35 @@ +FROM thomasbisignani/docker-apache-php-oracle +# Autre images intéressantes : https://hub.docker.com/r/alexisno/apache-php-dev/ + +MAINTAINER Bertrand GAUTHIER <bertrand.gauthier at unicaen.fr> + +#ENV http_proxy http://10.14.128.99:3128 +# Remplacé par "--build-arg http_proxy=http://10.14.128.99:3128" lors du build +ARG http_proxy + +RUN apt-get update +RUN apt-get install -y vim wget git subversion sqlite +RUN apt-get install -y php5-sqlite php5-mysql php5-ldap php5-intl php5-curl php5-xdebug php-apc + +RUN echo "date.timezone=Europe/Paris" >> /etc/php5/apache2/conf.d/01-timezone.ini &&\ + echo "error_reporting = E_ALL\ndisplay_startup_errors = 1\ndisplay_errors = 1" >> /etc/php5/apache2/conf.d/01-errors.ini &&\ + echo "error_reporting = E_ALL\ndisplay_startup_errors = 1\ndisplay_errors = 1" >> /etc/php5/cli/conf.d/01-errors.ini &&\ + echo "upload_max_filesize = 51M\npost_max_size = 60M" >> /etc/php5/apache2/conf.d/02-uploads.ini &&\ + echo "memory_limit = 256M" >> /etc/php5/apache2/conf.d/03-memory.ini &&\ + echo "xdebug.remote_enable=1" >> /etc/php5/apache2/conf.d/20-xdebug.ini &&\ + echo "xdebug.remote_connect_back=1" >> /etc/php5/apache2/conf.d/20-xdebug.ini &&\ + echo "xdebug.profiler_enable_trigger=1" >> /etc/php5/apache2/conf.d/20-xdebug.ini &&\ + echo "xdebug.max_nesting_level=250" >> /etc/php5/apache2/conf.d/20-xdebug.ini + +# Install Composer +RUN cd $HOME &&\ + curl -sS https://getcomposer.org/installer | php &&\ + chmod +x composer.phar &&\ + mv composer.phar /usr/local/bin/composer + +RUN rm -f /etc/apache2/sites-enabled/000-default.conf + +COPY apache.conf /etc/apache2/sites-available/app.conf +RUN a2ensite app + +ENTRYPOINT ["/usr/sbin/apache2", "-D", "FOREGROUND"] diff --git a/apache.conf b/apache.conf new file mode 100644 index 0000000000000000000000000000000000000000..bf3f5ff325c3e340982ca775b21d14c8d905de38 --- /dev/null +++ b/apache.conf @@ -0,0 +1,16 @@ +<VirtualHost *:80> + ServerName localhost + DocumentRoot /opt/app/public + + RewriteEngine On + + <Directory /opt/app/public> + DirectoryIndex index.php + AllowOverride All + Require all granted + </Directory> + + ErrorLog ${APACHE_LOG_DIR}/error.log + CustomLog ${APACHE_LOG_DIR}/access.log combined + #LogLevel debug + </VirtualHost>