From 6b91c56c4e73fda9d10d11cecc9f938a64ccd710 Mon Sep 17 00:00:00 2001 From: Alexei Znamensky <103110+russoz@users.noreply.github.com> Date: Fri, 3 Dec 2021 19:27:03 +1300 Subject: [PATCH] java_cert - invoke run_command passing list (#3835) * java_cert - invoke run_command passing list * added changelog fragment --- changelogs/fragments/3835-java-cert-run-list.yaml | 2 ++ plugins/modules/system/java_cert.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 changelogs/fragments/3835-java-cert-run-list.yaml diff --git a/changelogs/fragments/3835-java-cert-run-list.yaml b/changelogs/fragments/3835-java-cert-run-list.yaml new file mode 100644 index 0000000000..7cebe7d2cb --- /dev/null +++ b/changelogs/fragments/3835-java-cert-run-list.yaml @@ -0,0 +1,2 @@ +minor_changes: + - java_cert - calling ``run_command`` with arguments as ``list`` instead of ``str`` (https://github.com/ansible-collections/community.general/pull/3835). diff --git a/plugins/modules/system/java_cert.py b/plugins/modules/system/java_cert.py index 515d5269c9..afeab9d9e7 100644 --- a/plugins/modules/system/java_cert.py +++ b/plugins/modules/system/java_cert.py @@ -439,7 +439,7 @@ def delete_cert(module, executable, keystore_path, keystore_pass, alias, keystor def test_keytool(module, executable): ''' Test if keytool is actually executable or not ''' - module.run_command("%s" % executable, check_rc=True) + module.run_command([executable], check_rc=True) def test_keystore(module, keystore_path):