Help with the External scripts App

Thanks. It’s working now! :slight_smile:

Executing
sudo -u www-data php -f /var/www/nextcloud/cron.php
was the solution.

Script:

script.sh:
#/bin/bash
/usr/bin/jpegoptim -m90 /var/nc_data"$1"
/usr/bin/php /var/www/nextcloud/occ files:scan --path="$1"

Works fine for me!

2 Likes