Skip to content

Commit 9314b44

Browse files
gsmetholly-cummins
authored andcommitted
Fix Podman detection on Windows
Fixes quarkusio#32106
1 parent 272dd24 commit 9314b44

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

core/runtime/src/main/java/io/quarkus/runtime/util/ContainerRuntimeUtil.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -77,15 +77,17 @@ public static ContainerRuntime detectContainerRuntime(boolean required) {
7777
dockerAvailable = dockerVersionOutput.contains("Docker version");
7878
if (dockerAvailable) {
7979
// Check if "docker" is an alias to "podman"
80-
if (dockerVersionOutput.startsWith("podman version")) {
80+
if (dockerVersionOutput.startsWith("podman version") ||
81+
dockerVersionOutput.startsWith("podman.exe version")) {
8182
storeContainerRuntimeInSystemProperty(ContainerRuntime.PODMAN);
8283
return ContainerRuntime.PODMAN;
8384
}
8485
storeContainerRuntimeInSystemProperty(ContainerRuntime.DOCKER);
8586
return ContainerRuntime.DOCKER;
8687
}
8788
podmanVersionOutput = getVersionOutputFor(ContainerRuntime.PODMAN);
88-
podmanAvailable = podmanVersionOutput.startsWith("podman version");
89+
podmanAvailable = podmanVersionOutput.startsWith("podman version") ||
90+
podmanVersionOutput.startsWith("podman.exe version");
8991
if (podmanAvailable) {
9092
storeContainerRuntimeInSystemProperty(ContainerRuntime.PODMAN);
9193
return ContainerRuntime.PODMAN;

0 commit comments

Comments
 (0)