JP Site Search - CLI and Cron
Article Index
- JP Site Search
- What is JP Site Search?
- What is Typesense?
- Typesense Hosting Options
- Recommended Typesense Server Setup
- Quick Docker Example
- Installation
- Initial Setup
- Sources and Providers
- Joomla Articles
- Joomla Contacts
- Joomla Categories
- DOCman Provider Add-on
- Indexing
- CLI and Cron
- Frontend Module
- Autocomplete Layouts
- Full Search Page
- Analytics and Search Quality
- Diagnostics
- Security Model
- Troubleshooting
- Recommended First Setup
- All Pages
Page 15 of 23
CLI and Cron
JP Site Search supports selective source indexing from CLI and cron. This is useful for large websites where different content types should be indexed at different frequencies.
CLI examples
php cli/joomla.php jpsitesearch:index --source=all
php cli/joomla.php jpsitesearch:index --source=articles
php cli/joomla.php jpsitesearch:index --source=contacts
php cli/joomla.php jpsitesearch:index --source=categories
php cli/joomla.php jpsitesearch:index --source=documents
On DDEV, run the command through the container:
ddev exec php web/cli/joomla.php jpsitesearch:index --source=all
Cron examples
index.php?option=com_jpsitesearch&task=cron.index&token=YOUR_TOKEN&source=all
index.php?option=com_jpsitesearch&task=cron.index&token=YOUR_TOKEN&source=articles
index.php?option=com_jpsitesearch&task=cron.index&token=YOUR_TOKEN&source=contacts
index.php?option=com_jpsitesearch&task=cron.index&token=YOUR_TOKEN&source=categories
index.php?option=com_jpsitesearch&task=cron.index&token=YOUR_TOKEN&source=documents
Example schedule:
- Contacts: hourly
- Articles: nightly
- Documents: nightly or several times per day
- All public content: weekly or after major upgrades