NC20.0.4 problems with temp directory

Hi,

I searched alot for my issue here but didn’t find a solution.

Short description of the situation:
I’ve a raspberry 4 with an external HD, from which I boot the raspberry.
I installed docker and portainer, after that I start to install the docker container for NC.

The following steps I do:

After that I had an installation of

  • NCP v13.2.0
  • NC v20.0.2.0

In the config file config.php I got the following entry for the temp directory:

‘tempdirectory’ => ‘/var/www/nextcloud/data/tmp’

But this directory don’t exists neither on the HDD nor in the container itself. The big surprise was that everything works fine. I could upload files no matter what size and see apps in the app section.

Then I upgrade the NCP to version 1.34.1 and NC to version 20.0.4 via the NCP webinterface.
After that I get the following messages:

Temporary directory /var/www/nextcloud/data/tmp is not present or writable

After some research I found that I have to change the variable ‘tempdirectory’ in config.php. So I did, now the path is set to:

‘tempdirectory’ => ‘/data-ro/nextcloud/data/tmp’,

and the message is gone and the directory I also can find in the container.

After this change I now have the problem that I can’t upload files any more. So I do another “short” research and find that I have to change the temp-directory in the php.ini also.
And here I stuck. I found the php.ini in the container under /etc/php/7.3/fpm/php.ini but how can I change the variable “sys_temp_dir” so it is persistante even I restart the container.
In the php.ini the variable is also set to:

sys_temp_dir = /var/www/nextcloud/data/tmp

I try to copy the file out of the container, make the changes and put it back. But after restarting the container there was the old values.

Maybe I do something totaly wrong, it’s my first time to work with docker and all the other stuff.
Hope somebody can help and I explain my problem understandable