1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

[PR #7028/3a7044e2 backport][stable-7] ejabberd_user: better error when command not installed (#7030)

ejabberd_user: better error when command not installed (#7028)

* ejabberd_user: better error when command not installed

* add changelog frag

(cherry picked from commit 3a7044e2b8)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
patchback[bot] 2023-07-29 21:40:06 +02:00 committed by GitHub
parent 1dad95370e
commit 08d89a2f85
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View file

@ -0,0 +1,2 @@
bugfixes:
- ejabberd_user - provide meaningful error message when the ``ejabberdctl`` command is not found (https://github.com/ansible-collections/community.general/pull/7028, https://github.com/ansible-collections/community.general/issues/6949).

View file

@ -122,7 +122,7 @@ class EjabberdUser(object):
""" This method will run the any command specified and return the
returns using the Ansible common module
"""
cmd = [self.module.get_bin_path('ejabberdctl'), cmd] + options
cmd = [self.module.get_bin_path('ejabberdctl', required=True), cmd] + options
self.log('command: %s' % " ".join(cmd))
return self.module.run_command(cmd)