I have a crontab containing around 80 entries on a server. And I would like to manage that crontab using Ansible.
Ideally I would copy the server's crontab to my Ansible directory and create an Ansible task to ensure that crontab is set on the server.
But the cron module only seems to manage individual cron entries and not whole crontab files.
Manually migrating the crontab to Ansible tasks is tedious. And even if I find or make a tool that does it automatically, I feel the YAML file will be far less readable than the crontab file.
Any idea how I can handle that big crontab using Ansible?
copy
module to copy the crontab to the appropriate location? – larsks