GoogleCloudPlatform / click-to-deploy

Source for Google Click to Deploy solutions listed on Google Cloud Marketplace.
Apache License 2.0
730 stars 447 forks source link

WordPress-ha (Google Click to Deploy VM) - upload_max_filesize in php.ini #1158

Open chateauvieux opened 3 years ago

chateauvieux commented 3 years ago

Category:

Virtual machines

Type:


The upload_max_filesize in the Google Click-to-Deploy wordpress-ha VM image is limited to 2Mb !!! (which is not the case for the wordpress VM image, where the limit is set to 100Mb). It would be good to have this limit increased for the wordpress-ha image too. Even better, this setting should be setable by a config parameter.

Indeed, I have not found any other way to increase the limit than to bake my own VM using imagebuilder. That is a long long way to go for such a simple tweak, which should really be allowed by configuration. (the 'simple hacks' suggested in other issues, such as adding directives to .htaccess, .user.ini, wp-config.php or the DocRoot's php.ini did NOT help of course, as the default php.ini is more restrictive - I managed somehow to get a 8Mb upload limit, but still very far from what I needed).

And when I baked my own image using the C2D chef template, I came to realize that this Tweak had already been done in the wordpress VM. A pity that was not true for wordpress-ha...

armandomiani commented 3 years ago

@chateauvieux ,

As an user how would be the best way for you to configure this setting?

I imagine we could include a custom path to PHP config, so users can create custom configs in this folder, then, being able to set up any PHP config, not only upload_max_filesize. It would work for you?

Best regards,

Armando Miani

chateauvieux commented 3 years ago

Yes, this would definitely work !