diff --git a/cron.php b/cron.php index 26ede8d9a843..f482b2024661 100644 --- a/cron.php +++ b/cron.php @@ -40,4 +40,8 @@ } echo 'Please use ./occ system:cron' . PHP_EOL; -exit(1); +$return = \system('./occ system:cron'); +// in case of an error while cron execution we exit with error code as well +if ($return === false) { + exit(1); +}