Rename nonroot-custom-php-config to apply last
The docker-compose manifest example for the nonroot image mounts `nonroot-custom-php-config.ini` to `/usr/local/etc/php/conf.d/` to enable customizing the php configuration using an external file. However, files inside that folder are loaded in lexicographical order and a variable's effective value is determined by the last assigning statement. As a result, any variable values set in `roundcube-defaults.ini` override values set by the above file as demonstrated below:
```
$ docker exec -it roundcubemail /bin/bash -c "grep upload_max_filesize /usr/local/etc/php/conf.d/*; php -i | grep ^upload_max_filesize"
/usr/local/etc/php/conf.d/nonroot-custom-php-config.ini:upload_max_filesize=25M
/usr/local/etc/php/conf.d/roundcube-defaults.ini:upload_max_filesize=5M
upload_max_filesize => 5M => 5M
```
Instead, external ini file overrides should be loaded *after* roundcube defaults.
This change renames `nonroot-custom-php-config.ini` so that it loads after `roundcube-defaults.ini`.
```
$ docker exec -it roundcubemail /bin/bash -c "grep upload_max_filesize /usr/local/etc/php/conf.d/*; php -i | grep ^upload_max_filesize"
/usr/local/etc/php/conf.d/roundcube-defaults.ini:upload_max_filesize=5M
/usr/local/etc/php/conf.d/zzz-nonroot-custom-php-config.ini:upload_max_filesize=25M
upload_max_filesize => 25M => 25M
```
合并状态:未合并 关闭于 2025-12-18 1 条评论