{"record":{"id":"95b33edfcaa8acb2","repo":"quarkusio/quarkus","slug":"no-container-cli-was-found-make-sure-you-have-eit","errorCode":null,"errorMessage":"No container CLI was found. Make sure you have either Docker or Podman CLI installed in your environment.","messagePattern":"No container CLI was found\\. Make sure you have either Docker or Podman CLI installed in your environment\\.","errorType":"exception","errorClass":"IllegalStateException","httpStatus":null,"severity":"critical","filePath":"core/deployment/src/main/java/io/quarkus/deployment/util/ContainerRuntimeUtil.java","lineNumber":79,"sourceCode":"    }\n\n    public static ContainerRuntime detectContainerRuntime(boolean required, List<ContainerRuntime> orderToCheckRuntimes) {\n        return detectContainerRuntime(required, false, orderToCheckRuntimes);\n    }\n\n    public static ContainerRuntime detectContainerRuntime(boolean required, boolean silent,\n            List<ContainerRuntime> orderToCheckRuntimes) {\n        ContainerRuntime containerRuntime = loadContainerRuntimeFromSystemProperty();\n        if ((containerRuntime != null) && orderToCheckRuntimes.contains(containerRuntime)) {\n            return containerRuntime;\n        }\n\n        final ContainerRuntime containerRuntimeEnvironment = getContainerRuntimeEnvironment(orderToCheckRuntimes);\n        if (containerRuntimeEnvironment == ContainerRuntime.UNAVAILABLE) {\n            storeContainerRuntimeInSystemProperty(ContainerRuntime.UNAVAILABLE);\n\n            if (required) {\n                throw new IllegalStateException(\"No container CLI was found. \"\n                        + \"Make sure you have either Docker or Podman CLI installed in your environment.\");\n            }\n\n            return ContainerRuntime.UNAVAILABLE;\n        }\n\n        // we have a working container environment, let's resolve it fully\n        containerRuntime = fullyResolveContainerRuntime(containerRuntimeEnvironment, silent);\n\n        storeContainerRuntimeInSystemProperty(containerRuntime);\n\n        return containerRuntime;\n    }\n\n    private static ContainerRuntime getContainerRuntimeEnvironment(List<ContainerRuntime> orderToCheckRuntimes) {\n        // Docker version 19.03.14, build 5eb3275d40\n\n        // Check if Podman is installed","sourceCodeStart":61,"sourceCodeEnd":97,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/core/deployment/src/main/java/io/quarkus/deployment/util/ContainerRuntimeUtil.java#L61-L97","documentation":"ContainerRuntimeUtil.detectContainerRuntime(required=true) probes for a Docker or Podman CLI in $PATH (honoring the quarkus.native.container-runtime system property / detection order). If neither executable is found and a container runtime is required, it throws IllegalStateException telling the user to install Docker or Podman. Used by container-based builds (e.g. native image builds in container, Dev Services image operations).","triggerScenarios":"Running a Quarkus build step that requires a container (e.g. mvn package -Dnative -Dquarkus.native.container-build=true) on a machine with no docker or podman executable on $PATH; or detection is restricted via detectContainerRuntime(required, orderToCheckRuntimes) to runtimes that are absent.","commonSituations":"CI containers without Docker socket/CLI; Docker Desktop not installed; running inside an already-containerized build where nested Docker is unavailable; typo in quarkus.native.container-runtime so it is ignored.","solutions":["Install Docker Desktop/Engine or Podman and ensure the CLI is on $PATH (docker version / podman version must work)","If the runtime is installed but not detected, set -Dquarkus.native.container-runtime=podman (or docker) explicitly","If you don't need container-based builds, drop -Dquarkus.native.container-build=true and use a local GraalVM instead","For container-image builds, check the daemon is running; if you only need detection to be optional use detectContainerRuntime(false)"],"exampleFix":"// before (CI without docker)\nmvn package -Dnative -Dquarkus.native.container-build=true\n// after (option A: install docker CLI+daemon, or option B: local GraalVM)\nmvn package -Dnative -Dquarkus.graalvm.home=/path/to/graalvm","handlingStrategy":"fallback","validationCode":"static void requireContainerCli() {\n    try {\n        new ProcessBuilder(\"docker\", \"version\").start();\n    } catch (Exception e1) {\n        try {\n            new ProcessBuilder(\"podman\", \"version\").start();\n        } catch (Exception e2) {\n            throw new IllegalStateException(\"Neither docker nor podman CLI found on PATH\");\n        }\n    }\n}\n","typeGuard":null,"tryCatchPattern":"try {\n    ContainerRuntimeUtil.detectContainerRuntime();\n} catch (IllegalStateException e) {\n    throw new IllegalStateException(\"Install Docker/Podman or disable container builds (-Dquarkus.native.container-build=false)\", e);\n}\n","preventionTips":["Verify `docker version` or `podman version` works in the same environment/user that runs the build","In CI images, install docker-cli (or podman) as part of the image","Set -Dquarkus.native.container-runtime=docker|podman when both may be present","Use local GraalVM builds to avoid needing a container CLI at all"],"tags":["docker","podman","container","environment"],"backgroundTag":"container-cli-not-found","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}