Download the PHP package bentools/crontab-bundle without Composer
On this page you can find all versions of the php package bentools/crontab-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download bentools/crontab-bundle
More information about bentools/crontab-bundle
Files in bentools/crontab-bundle
Package crontab-bundle
Short Description Generates a crontab based on the app directory.
License MIT
Informations about the package crontab-bundle
Crontab Bundle
An easy way to generate a crontab based on the application path.
Unlike similar Symfony bundles, this one does not provide a worker, it actually replaces the user's crontab.
⚠️ Do not use this if your user's crontab may by altered by another process!
[!IMPORTANT]
This repository is no longer maintained and may be removed in a near future. You may consider creating a fork if you still require it.
Installation
This bundle is compatible with Symfony 4/5+. Use 0.1.*
tag for earlier versions compatibility.
With Symfony Flex, you're already done!
Usage
Create a sample crontab in config/crontab.dist
:
As you can see, {%kernel.project_dir%}
is a container parameter.
It will be replaced at runtime with its current value. You can use any container parameter wrapped with curly braces.
Preview
This will give you a preview of your crontab:
Apply
To apply your crontab, run this:
Now if you execute crontab -l
in your shell you should see something like this:
FAQ
Can I use any container parameter?
Yes.
I don't want the dist file to be config/crontab.dist
. Can I change that?
Sure: create a config/packages/bentools_crontab.yaml
and change the dist_file
parameter:
What are the command options?
I already have a crontab for the user running my app. Will it replace it?
Yes. Use this bundle only if you consider it to be the only crontab entry point.
Tests
License
MIT
All versions of crontab-bundle with dependencies
symfony/console Version ^4.0|^5.0
symfony/framework-bundle Version ^4.0|^5.0
symfony/process Version ^4.0|^5.0
symfony/yaml Version ^4.0|^5.0