First of all we need to set up a cron job to do the regular housekeeping that nextcloud needs. Currently, it kicks off this activity whenever a page loads but as more content gets added this begins to become a bottleneck. So, in a terminal session do the following as root:
- crontab -u wwwrun -e
- This brings up an editor (vim) for the cron jobs assigned to the user wwwrun (which is the account nextcloud runs under). The editor commands are somewhat cryptic...to go into insert mode, press i and the cursor will move to the top of the screen
- Enter (or cut and paste) the following: */5 * * * * php -f /srv/www/htdocs/nextcloud/cron.php
- Do not press Enter!
- Now you are done, press Escape to get out of editing mode and then :q to quit and save.
- This will have scheduled the Nextcloud housekeeping to run every 5 minutes
- In a browser, log into Nextcloud as the admin and navigate to the Settings | Basic Settings screen
- In the top Background Jobs section, click on Cron (you have to enter the admin password again to confirm).
- Navigate to /srv/www/htdocs/nextcloud/config/ and open config.php in kate (or your text editor of choice).
- In the trusted domains_array add some entries after 0 => 'localhost', so that the Nextcloud server will work when accessed via other URL's besides localhost. I would suggest the following (adapted to your setup)...
- 1 => 'the-ip-address-of-the-server',
- 2 => 'servername.domain.com',
- 3 => 'servername.localdomain',
No comments:
Post a Comment