I have been playing around with this a bit more and the issues seem to be with the following lines under services.nextcloud.extraOptions in the .nix config.
memcache.distributed = "\OC\Memcache\Redis";
memcache.locking = "\OC\Memcache\Redis";
This leads to the following in the /var/lib/nextcloud/config/config.php:
'memcache' =>
array (
'distributed' => '\\OC\\Memcache\\Redis',
'locking' => '\\OC\\Memcache\\Redis',
),
The above kind of looks correct, but does not seem to be working. This is evident by the redis-cli monitor test and when you go to the Nextcloud serverinfo page, e.g.:
https://redacted/ocs/v2.php/apps/serverinfo/api/v1/info
<memcache.local>\OC\Memcache\APCu</memcache.local>
<memcache.distributed>none</memcache.distributed>
<filelocking.enabled>yes</filelocking.enabled>
<memcache.locking>none</memcache.locking>
However, when I set these two option manually:
nextcloud-occ config:system:set memcache.distributed --value '\OC\Memcache\Redis'
nextcloud-occ config:system:set memcache.locking --value '\OC\Memcache\Redis'
I get the following in /var/lib/nextcloud/config/config.php:
'memcache.locking' => '\\OC\\Memcache\\Redis',
'memcache.distributed' => '\\OC\\Memcache\\Redis',
This does work with both the redis-cli monitor test and when you go to the Nextcloud serverinfo page, e.g.:
https://redacted/ocs/v2.php/apps/serverinfo/api/v1/info
<memcache.local>\OC\Memcache\APCu</memcache.local>
<memcache.distributed>\OC\Memcache\Redis</memcache.distributed>
<filelocking.enabled>yes</filelocking.enabled>
<memcache.locking>\OC\Memcache\Redis</memcache.locking>
I am not really sure how to resolve this such that these two option can be set in the .nix config and have Nextcloud accept them. Does anyone have a suggestion?
Thank you