[PR #11440/53e1e86b backport][stable-12] Logstash plugin version fix (#11450)

Logstash plugin version fix (#11440)

* logstash_plugin: fix argument order when using version parameter

* logstash_plugin: add integration tests

* logstash_plugin: add changelog fragment

(cherry picked from commit 53e1e86bcc)

Co-authored-by: Nicolas Boutet <amd3002@gmail.com>
This commit is contained in:
patchback[bot]
2026-01-26 06:29:35 +01:00
committed by GitHub
parent 4d05149b6c
commit 44dfe9e1ab
4 changed files with 82 additions and 1 deletions

View File

@@ -94,7 +94,7 @@ def parse_error(string):
def install_plugin(module, plugin_bin, plugin_name, version, proxy_host, proxy_port):
cmd_args = [plugin_bin, PACKAGE_STATE_MAP["present"], plugin_name]
cmd_args = [plugin_bin, PACKAGE_STATE_MAP["present"]]
if version:
cmd_args.extend(["--version", version])
@@ -102,6 +102,8 @@ def install_plugin(module, plugin_bin, plugin_name, version, proxy_host, proxy_p
if proxy_host and proxy_port:
cmd_args.extend([f"-DproxyHost={proxy_host}", f"-DproxyPort={proxy_port}"])
cmd_args.append(plugin_name)
cmd = " ".join(cmd_args)
if module.check_mode: