|
|
|
@ -19,6 +19,7 @@
|
|
|
|
|
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
#
|
|
|
|
|
import os
|
|
|
|
|
from ansible.module_utils.basic import AnsibleModule, is_executable
|
|
|
|
|
|
|
|
|
|
DOCUMENTATION = '''
|
|
|
|
|
---
|
|
|
|
@ -101,7 +102,7 @@ def main():
|
|
|
|
|
config=dict(required=False, type='path'),
|
|
|
|
|
server_url=dict(required=False),
|
|
|
|
|
username=dict(required=False),
|
|
|
|
|
password=dict(required=False),
|
|
|
|
|
password=dict(required=False, no_log=True),
|
|
|
|
|
supervisorctl_path=dict(required=False, type='path'),
|
|
|
|
|
state=dict(required=True, choices=['present', 'started', 'restarted', 'stopped', 'absent'])
|
|
|
|
|
)
|
|
|
|
@ -239,8 +240,5 @@ def main():
|
|
|
|
|
module.fail_json(name=name, msg="ERROR (no such process)")
|
|
|
|
|
take_action_on_processes(processes, lambda s: s in ('RUNNING', 'STARTING'), 'stop', 'stopped')
|
|
|
|
|
|
|
|
|
|
# import module snippets
|
|
|
|
|
from ansible.module_utils.basic import *
|
|
|
|
|
# is_executable from basic
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
|
main()
|
|
|
|
|