From c3940f16eb892ae9c2a24b5b766eef505c0d307a Mon Sep 17 00:00:00 2001 From: Yuri Kunde Schlesner Date: Thu, 8 Jan 2015 21:44:58 -0200 Subject: [PATCH] crypttab: Fix parameter checking with state=absent Only the `name` parameter is required when removing an entry, but the module tried to ensure at least one other parameter was set. --- lib/ansible/modules/extras/system/crypttab.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/extras/system/crypttab.py b/lib/ansible/modules/extras/system/crypttab.py index 5142a6cf327..ccd4102c66b 100644 --- a/lib/ansible/modules/extras/system/crypttab.py +++ b/lib/ansible/modules/extras/system/crypttab.py @@ -103,7 +103,7 @@ def main(): state = module.params['state'] path = module.params['path'] - if backing_device is None and password is None and opts is None: + if state != 'absent' and backing_device is None and password is None and opts is None: module.fail_json(msg="expected one or more of 'backing_device', 'password' or 'opts'", **module.params)