If you would like to get this app installed, maintained or need training, Contact Me to get current rates. Start the timer: $ systemctl start nextcloud-preview-generator.timerĭevelop and scale your apps globally with DigitalOcean and/or Vultr – or use shared hosting with no server maintenance required at. Systemd reload: $ systemctl daemon-reloadĪctivate the timer: $ systemctl enable nextcloud-preview-generator.timer You need to create 2 unit files:įile 1: $ sudo nano /etc/systemd/system/rviceĮxecStart=/usr/bin/php -f /var/www/html/nextcloud/occ preview:pre-generateįile 2: $ sudo nano /etc/systemd/system/nextcloud-preview-generator.timerĭescription=Run Nextcloud Preview Generator daily at 04:00 Systemd also has the possibility to run specific tasks at specific times or events. Using your favorite editor, add something like this, which will run the job at 04:00 (make sure to point to the correct directory of the ‘occ' file): 0 4 * * * /usr/bin/php -f /var/www/html/nextcloud/occ preview:pre-generate Or using systemd timers Setup Cron (or systemd timers) for the Nextcloud Preview GeneratorĪdd or create a new cronjob for the Nextcloud user: $ sudo crontab -e -u www-data How to run a cron manually (the example below is for nextcloud): $ sudo -u www-data php -f /var/www/html/nextcloud/cron.php Then enter the code below at the bottom (runs every 15 minutes): */15 * * * * php -f /var/www/nextcloud/cron.php The best/clearest info I have seen for using a cronjob with the preview generator app:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |