docker-moodle icon indicating copy to clipboard operation
docker-moodle copied to clipboard

Upload File limit for restoring a course?

Open LiFaytheGoblin opened this issue 2 years ago • 1 comments

When I try to restore a course of over 8.3MB, it tells me the course is too big image

To Reproduce

  • Create a test course of size S, include the activity logs and all
  • Export the course
  • Try to restore the course

Expected behavior I expect it to upload my file, since I don't see where it says that 8.3MB is the limit or else I would like to know where to change the limit. https://docs.moodle.org/311/en/File_upload_size did not really help.

Screenshots If applicable, add screenshots to help explain your problem.

Docker Version (please complete the following information):

  • OS: Ubuntu 20.04.4
  • Docker Version: Docker version 20.10.12, build e91ed57
  • Tag name of image if pulled from Docker Hub. [e.g. v3.1]: mysql 5, jhardison/moodle latest

Additional context Testing

LiFaytheGoblin avatar Mar 15 '22 08:03 LiFaytheGoblin

I solved this problem by adding the following to the Dockerfile, to raise the upload limit:

# Update PHP settings 
RUN sed -i "s/post_max_size.*/post_max_size = 0/" /etc/php/7.4/apache2/php.ini && \
sed -i "s/upload_max_filesize.*/upload_max_filesize = 128M/" /etc/php/7.4/apache2/php.ini && \
sed -i "s/max_execution_time.*/max_execution_time = 300/" /etc/php/7.4/apache2/php.ini

LiFaytheGoblin avatar Oct 10 '22 05:10 LiFaytheGoblin