padam87 / cron-bundle
A cron job manager for symfony console.
Installs: 48 223
Dependents: 0
Suggesters: 0
Security: 0
Stars: 11
Watchers: 4
Forks: 1
Open Issues: 0
Type:symfony-bundle
Requires
- php: ^8.1
- symfony/config: ^6.1 || ^7.0
- symfony/console: ^6.1 || ^7.0
- symfony/dependency-injection: ^6.1 || ^7.0
- symfony/process: ^6.1 || ^7.0
Requires (Dev)
- phpunit/phpunit: ^9.5
README
A cron job manager for symfony console.
Installation
A simple bundle install. No extra stuff.
composer require padam87/cron-bundle
new Padam87\CronBundle\Padam87CronBundle(),
Configuration
padam87_cron: log_dir: %cron_log_dir% variables: mailto: %cron_mailto% any_other_variable_you_might_need: 'some_value'
Usage (v3)
Please note that v2 versions of this bundle still support annotations.
Commands
cron:dump
dumps the cronfilecron:import
dumps the cronfile to the temp dir, and imports it
Basic
#[Job(minute: '5', hour: '0')] class MyCommand extends Command
Groups
#[Job(minute: '5',hour: '0', group: 'master')] class MyCommand extends Command
Output file
#[Job(minute: '5', hour: '0', logFile: 'my-command.log')] class MyCommand extends Command