aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/security/check_versions/src/k8s_bin_versions_inspector.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/security/check_versions/src/k8s_bin_versions_inspector.py b/test/security/check_versions/src/k8s_bin_versions_inspector.py
index bda7322f5..e5a59b923 100644
--- a/test/security/check_versions/src/k8s_bin_versions_inspector.py
+++ b/test/security/check_versions/src/k8s_bin_versions_inspector.py
@@ -381,10 +381,12 @@ def determine_versions_abstraction(
"""
commands = ([binary, "--version"] for binary in binaries)
+ commands_old = ([binary, "-version"] for binary in binaries)
+ commands_all = itertools.chain(commands, commands_old)
# TODO: This list comprehension should be parallelized
results = (
- sync_post_namespaced_pod_exec(api, container, command) for command in commands
+ sync_post_namespaced_pod_exec(api, container, command) for command in commands_all
)
successes = (
@@ -439,7 +441,7 @@ def determine_versions_of_java(
List of installed OpenJDK versions.
"""
- extractor = re.compile("openjdk ([0-9.]+)")
+ extractor = re.compile("openjdk [version\" ]*([0-9._]+)")
binaries = generate_java_binaries()