diff --git a/distillery/resources/compose/barrel/Dockerfile b/distillery/resources/compose/barrel/Dockerfile index 8287a14..faa48cb 100644 --- a/distillery/resources/compose/barrel/Dockerfile +++ b/distillery/resources/compose/barrel/Dockerfile @@ -60,15 +60,13 @@ ADD patch/easyrdf.patch /patch/easyrdf.patch # Add wisski configuration ADD conf/ports.conf /etc/apache2/ports.conf ADD conf/wisski.conf /etc/apache2/sites-available/wisski.conf +ADD conf/wisski.ini /usr/local/etc/php/conf.d/wisski.ini RUN a2ensite wisski # volumes for composer VOLUME /var/www/.composer VOLUME /var/www/data -# increase the php memory limit to 4g -RUN echo 'memory_limit=4G' > /usr/local/etc/php/conf.d/memory-limit.ini - # Add and configure the entrypoint ADD scripts/entrypoint.sh /entrypoint.sh ENTRYPOINT [ "/entrypoint.sh" ] diff --git a/distillery/resources/compose/barrel/conf/wisski.ini b/distillery/resources/compose/barrel/conf/wisski.ini new file mode 100644 index 0000000..bed4795 --- /dev/null +++ b/distillery/resources/compose/barrel/conf/wisski.ini @@ -0,0 +1,13 @@ +; File Uploads up to 250 MB +; Seems to be reasonable compromise between the default (2MB) and maximum available space +file_uploads = On +upload_max_filesize = 250M +post_max_size = 250M + +; Composer uses an absurd amount of memory +; 4GB ought to be enough +memory_limit = 4G + +; If execution time turns out to be a problem +; we should uncomment this +; max_execution_time = 600 \ No newline at end of file diff --git a/distillery/resources/compose/web/docker-compose.yml b/distillery/resources/compose/web/docker-compose.yml index b4bb7ce..0b7c99d 100644 --- a/distillery/resources/compose/web/docker-compose.yml +++ b/distillery/resources/compose/web/docker-compose.yml @@ -10,6 +10,7 @@ services: - "443:443" volumes: - "vhost:/etc/nginx/vhost.d" + - "./global.conf:/etc/nginx/conf.d/global.conf:ro" - "htpasswd:/etc/nginx/htpasswd" - "html:/usr/share/nginx/html" - "/var/run/docker.sock:/tmp/docker.sock:ro" diff --git a/distillery/resources/compose/web/global.conf b/distillery/resources/compose/web/global.conf new file mode 100644 index 0000000..f814838 --- /dev/null +++ b/distillery/resources/compose/web/global.conf @@ -0,0 +1,3 @@ +# update the max body size to fit with php's configuration. +# should be kept in sync with distillery/resources/compose/barrel/conf/wisski.ini. +client_max_body_size 250m; \ No newline at end of file