Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,059 of 9,059 pages
About the help in other languages
All help pages

exp:installcrontab

Show, add or remove the cron job of the installation: the crontab lines that run its cronjob parts (--add and --remove: dry run unless --apply).

Download as PDF

Address: https://doc.exponential.earth/learninminutes/exphelp/viewer/examples/commands/installcrontab.md

On this page

exp:installcrontab

Show, add or remove the cron job of the installation: the crontab lines that run its cronjob parts (--add and --remove: dry run unless --apply).

Script bin/php/installcrontab.php, code in kernel/private/classes/commands/installcrontab.php. Run it from the installation root, as the user the web server runs as:

./console exp:installcrontab --help
php bin/php/installcrontab.php --help

Help text

Show, add or remove the cron job of this installation: the crontab lines that run its cronjob
parts (runcronjobs.php) with the PHP binary and the siteaccess each needs, in the crontab of the
system user that owns the installation directory, between the lines
"# BEGIN Exponential cronjobs: <root>" and "# END Exponential cronjobs: <root>".
The parts are cronjob.ini [CrontabSettings] Parts[] that the installation defines (an extension's
when it is active), the schedules [AdminSettings] CrontabSchedule_<part>. --add replaces the block
or appends it and keeps every other line; a part another line of the crontab runs already is left
out. Run it as the owner of the installation or as root (crontab -u <owner>); otherwise, or without a
crontab command, it prints the lines to add by hand. Prints PASS or FAIL at the end.
--add and --remove change nothing without --apply: they show the block and the lines of the crontab
that would change. --dry-run is still accepted and means the same as no flag; --apply together with
--dry-run is a usage error (exit 2).

Example: php bin/php/installcrontab.php --show
         php bin/php/installcrontab.php --add
         php bin/php/installcrontab.php --add --apply
         php bin/php/installcrontab.php --remove --apply

Options

OptionValueHelp
--applyWith --add or --remove: write the crontab (the default shows what would change)
--dry-runThe default, kept for scripts that pass it: show what would change, change nothing
--showThe planned lines, the block in the crontab and the last runs (the default)
--addAdd or update the block
--removeRemove the block
--admin-siteaccessrequiredThe siteaccess of the admin parts (default: [CrontabSettings] AdminSiteAccess, else admin)

Read from the option definitions in the code (startup(), getOptions(), options() or ezcConsoleOption). Every script also takes the standard options of the script framework (--help, --siteaccess, --debug, --quiet, --allow-root-user ...).


Generated by ./console exp:help:examples from bin/php/installcrontab.php, kernel/private/classes/commands/installcrontab.php. Do not edit this page: change the source and generate again (how). Free documentation: GFDL 1.3 or later.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x