wernerfred / docker-rainloop

Host your own rainloop using docker 🐳📧
GNU Affero General Public License v3.0
14 stars 2 forks source link

php file upload options are to small = 2M #49

Open chrisXmz opened 2 years ago

chrisXmz commented 2 years ago

Hello All,

first of all i have to say thank you very much for creating and sharing your Project on GitHUB! Thanks :-)

now the issue itself: When I add an Attachement to an new email I got an red Alert with the subject "Filesize to big"

In the Administation Panal I can see php is set to: PHP: upload_max_filesize = 2M; post_max_size = 8M

Can you change this setting within the Dockerfile crating progress for us please?

I would like to set this value to the maximum of my SMTP-Server. Or, alternatively to some value like 25MB

Thank you very much!

Pictures of the Issue: 2022-10-07_11-38-10 2022-10-07_11-40-17 2022-10-07_11-41-10

chrisXmz commented 2 years ago

Hello again,

in the meantime I have found a workaround for my Problem.

First I had to create a local (and default value overwriting) configuration for php.
This is the Contend of my file local_php.ini

file_uploads = On
memory_limit = 64M
upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 600

Then I link the created file local_php.ini into the container as local.ini. This is a volume mount option in docker-compose:

# Example:
   volumes:
      - ./php_ini/local_php.ini:/usr/local/etc/php/conf.d/local.ini

After a docker-compose down and a docker-compose up -d the new setting is active and can be checked within the admin panel. Here you should see 64M as limit.

By the way, the maximum send limit for an email is the smallest allowed size of one of the SMTP Servers in exchanging situation of the SMTPs. So the max 64M can be still to high, in case you will hit a SMTP-Server with a smaller sending and receiving size setting.

I hope this will help someone.

br Chris

pscriptos commented 9 months ago

Thank you for sharing your workaround with us.

This is now also helping me with my problem. Thank you very much!

chrisXmz commented 9 months ago

Thank you for sharing your workaround with us.

This is now also helping me with my problem. Thank you very much!

Hi patrickasmus thank you for your feedback! I'm happy to hear my workaround is helpfully to others.

Have a nice Week! :-)