How to get access to php.ini file

I tried that. The directory /usr/local/etc/php is not defined as a volume in the wordpress default Dockerfile so no way to add that.

$ docker image inspect wordpress:latest --format '{{.Config.Volumes}}'
map[/var/www/html:{}]

I tried another method of modifying the uploads by a config file addition to the /var/www/html directory with a volume mount of the file. The directory was overwritten by the PHP initialization and the file was gone.