diff --git a/nextcloud/main.yaml b/nextcloud/main.yaml index 13bfbfa..412ba5f 100644 --- a/nextcloud/main.yaml +++ b/nextcloud/main.yaml @@ -109,7 +109,6 @@ data: 'redis' => array( 'host' => getenv('REDIS_HOST'), 'password' => getenv('REDIS_HOST_PASSWORD_FILE') ? trim(file_get_contents(getenv('REDIS_HOST_PASSWORD_FILE'))) : (string) getenv('REDIS_HOST_PASSWORD'), - 'dbindex' => 1, ), ); @@ -453,8 +452,9 @@ spec: - /bin/sh - -c - | - echo "*/1 * * * * php -f /var/www/html/cron.php" > /etc/crontabs/www-data - exec busybox crond -f -L /dev/stdout + mkdir -p /etc/crontabs + echo "*/1 * * * * su -s /bin/sh -c 'php -f /var/www/html/cron.php' \#33" > /etc/crontabs/root + exec busybox crond -c /etc/crontabs -f -L /dev/stdout env: - name: POSTGRES_HOST valueFrom: diff --git a/nextcloud/src/values.yaml b/nextcloud/src/values.yaml index d386a69..3b4c1b2 100644 --- a/nextcloud/src/values.yaml +++ b/nextcloud/src/values.yaml @@ -642,8 +642,9 @@ cronjob: - /bin/sh - -c - | - echo "*/1 * * * * php -f /var/www/html/cron.php" > /etc/crontabs/www-data - exec busybox crond -f -L /dev/stdout + mkdir -p /etc/crontabs + echo "*/1 * * * * su -s /bin/sh -c 'php -f /var/www/html/cron.php' \#33" > /etc/crontabs/root + exec busybox crond -c /etc/crontabs -f -L /dev/stdout # Uses a Kubernetes CronJob to execute the Nextcloud cron tasks # Note: can run as non-root user. Should run as same user as the Nextcloud pod.