genzouw.cron
Ansible Cron Role
cronis an ansible role which:
- installs cron
- adds cron tasks
- configures service
Installation
Using ansible-galaxy:
$ ansible-galaxy install franklinkim.cron
Using arm (Ansible Role Manager):
$ arm install franklinkim.cron
Using git:
$ git clone https://github.com/weareinteractive/ansible-cron.git
Variables
Here is a list of all the default variables for this role, which are also available in defaults/main.yml.
# cron_tasks
# - '*/5 * * * * /bin/sh /absolute/path/to/cron.sh'
#
# list of cron entries
cron_tasks: []
# service name
cron_service_name: cron
# start on boot
cron_service_enabled: yes
# current state: started, stopped
cron_service_state: started
Handlers
These are the handlers that are defined in handlers/main.yml.
restart cron
Example playbook
- host: all
roles:
- franklinkim.cron
vars:
crontab_tasks:
- '*/5 * * * * /bin/sh /absolute/path/to/cron.sh'
Testing
$ git clone https://github.com/weareinteractive/ansible-cron.git
$ cd ansible-cron
$ vagrant up
Contributing
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests and examples for any new or changed functionality.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create new Pull Request
License
Copyright (c) We Are Interactive under the MIT license.
Install
ansible-galaxy install genzouw.cronLicense
mit
Downloads
92
Owner
Hadoop/Hive/Spark/GCP/AWS/Shell/Bash/Vim/PHP/JavaScript/Java/Docker/Docker-Compose/Kubernetes/MySQL/PostgreSQL/Oracle

