mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-11 16:44:22 -07:00
Don't allow cron module to delete cron_file without name parameter assignment
This commit is contained in:
parent
a43aaaecd0
commit
17cbbcdd30
1 changed files with 3 additions and 0 deletions
|
@ -455,6 +455,9 @@ def main():
|
||||||
if job is None and do_install:
|
if job is None and do_install:
|
||||||
module.fail_json(msg="You must specify 'job' to install a new cron job")
|
module.fail_json(msg="You must specify 'job' to install a new cron job")
|
||||||
|
|
||||||
|
if job and name is None and not do_install:
|
||||||
|
module.fail_json(msg="You must specify 'name' to remove a cron job")
|
||||||
|
|
||||||
if reboot:
|
if reboot:
|
||||||
if special_time:
|
if special_time:
|
||||||
module.fail_json(msg="reboot and special_time are mutually exclusive")
|
module.fail_json(msg="reboot and special_time are mutually exclusive")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue