diff options
author | Toshio Kuratomi <toshio@fedoraproject.org> | 2016-05-25 10:34:55 -0700 |
---|---|---|
committer | Toshio Kuratomi <toshio@fedoraproject.org> | 2016-05-25 10:36:16 -0700 |
commit | 3b69ef7e8b34d736770aed8f2b31cfec522ed2d8 (patch) | |
tree | 385f736f410947654e2b0ba7223a5bebf22dd960 | |
parent | d08fda9320628c8ec318ba4ade89b1fb6f71619d (diff) | |
download | ansible-3b69ef7e8b34d736770aed8f2b31cfec522ed2d8.tar.gz |
Add strings 'True' and 'False' as booleans as python bools converted to strings will look that way.
Workaround for custom modules which are using choices=BOOLEANS instead
of type='bool'.
-rw-r--r-- | lib/ansible/module_utils/basic.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/ansible/module_utils/basic.py b/lib/ansible/module_utils/basic.py index a8ed1b3b46..9456ad9dc1 100644 --- a/lib/ansible/module_utils/basic.py +++ b/lib/ansible/module_utils/basic.py @@ -27,8 +27,8 @@ # USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # -BOOLEANS_TRUE = ['yes', 'on', '1', 'true', 1, True] -BOOLEANS_FALSE = ['no', 'off', '0', 'false', 0, False] +BOOLEANS_TRUE = ['yes', 'on', '1', 'true', 'True', 1, True] +BOOLEANS_FALSE = ['no', 'off', '0', 'false', 'False', 0, False] BOOLEANS = BOOLEANS_TRUE + BOOLEANS_FALSE # ansible modules can be written in any language. To simplify |