diff options
author | Fabio Alessandro Locati <me@fale.io> | 2016-12-05 16:19:27 +0000 |
---|---|---|
committer | Ryan Brown <sb@ryansb.com> | 2016-12-05 11:19:27 -0500 |
commit | 8cadf88e868eacd838f8e3786100ee500615f773 (patch) | |
tree | 44afe1fc69e2b264b77c54981464f5fdf67e3e49 | |
parent | 572daab063f32cb3b95e4ae161dcadf7c43085bf (diff) | |
download | ansible-modules-extras-8cadf88e868eacd838f8e3786100ee500615f773.tar.gz |
Make `main()` calls conditional - database (#3659)
-rw-r--r-- | database/misc/mongodb_user.py | 4 | ||||
-rw-r--r-- | database/misc/redis.py | 4 | ||||
-rw-r--r-- | database/postgresql/postgresql_ext.py | 3 | ||||
-rw-r--r-- | database/postgresql/postgresql_lang.py | 4 |
4 files changed, 11 insertions, 4 deletions
diff --git a/database/misc/mongodb_user.py b/database/misc/mongodb_user.py index e4280827..5e9453f9 100644 --- a/database/misc/mongodb_user.py +++ b/database/misc/mongodb_user.py @@ -445,4 +445,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * from ansible.module_utils.pycompat24 import get_exception -main() + +if __name__ == '__main__': + main() diff --git a/database/misc/redis.py b/database/misc/redis.py index 49d9cc23..6e906b24 100644 --- a/database/misc/redis.py +++ b/database/misc/redis.py @@ -341,4 +341,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * from ansible.module_utils.pycompat24 import get_exception -main() + +if __name__ == '__main__': + main() diff --git a/database/postgresql/postgresql_ext.py b/database/postgresql/postgresql_ext.py index b9fe87c4..9f14a182 100644 --- a/database/postgresql/postgresql_ext.py +++ b/database/postgresql/postgresql_ext.py @@ -189,5 +189,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * from ansible.module_utils.pycompat24 import get_exception -main() +if __name__ == '__main__': + main() diff --git a/database/postgresql/postgresql_lang.py b/database/postgresql/postgresql_lang.py index 8e4fad37..a2543295 100644 --- a/database/postgresql/postgresql_lang.py +++ b/database/postgresql/postgresql_lang.py @@ -285,4 +285,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * from ansible.module_utils.pycompat24 import get_exception -main() + +if __name__ == '__main__': + main() |