Skip to content

docker-cli broken in v26.1.1 with entrypoint is invalid. Keeps hanging forever. #5053

@Cytrian

Description

@Cytrian

Description

This command sometime, not always, fails when using docker-cli 26.1.1.
It does not always exit.

docker run --rm --entrypoint invalidcommand alpine param

The command does not always return now. I have to kill the docker-cli process with kill -9.

Reproduce

# docker run --rm --entrypoint invalidcommand alpine param
docker: Error response from daemon: failed to create task for container: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "invalidcommand": executable file not found in $PATH: unknown.

The error message is expected but the command does not always return now. I often have to kill the docker-cli process with kill -9.

The docker container seems to exit, but docker-cli does not.

We have a similar command in our build pipeline to check for distroless images, this breaks now.

Reinstalling docker-cli in previous version 26.1.0 solves the problem.
Verified on Ubuntu and Debian.

Expected behavior

docker run --rm --entrypoint invalidcommand alpine param
should always exit immediately.

docker version

Client: Docker Engine - Community
 Version:           26.1.1
 API version:       1.45
 Go version:        go1.21.9
 Git commit:        4cf5afa
 Built:             Tue Apr 30 11:48:20 2024
 OS/Arch:           linux/amd64
 Context:           default

Server: Docker Engine - Community
 Engine:
  Version:          26.1.1
  API version:      1.45 (minimum version 1.24)
  Go version:       go1.21.9
  Git commit:       ac2de55
  Built:            Tue Apr 30 11:48:20 2024
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          1.6.31
  GitCommit:        e377cd56a71523140ca6ae87e30244719194a521
 runc:
  Version:          1.1.12
  GitCommit:        v1.1.12-0-g51d5e94
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

docker info

Client: Docker Engine - Community
 Version:    26.1.1
 Context:    default
 Debug Mode: false

Server:
 Containers: 32
  Running: 21
  Paused: 0
  Stopped: 11
 Images: 40
 Server Version: 26.1.1
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: e377cd56a71523140ca6ae87e30244719194a521
 runc version: v1.1.12-0-g51d5e94
 init version: de40ad0
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.1.0-0.deb11.13-amd64
 Operating System: Debian GNU/Linux 11 (bullseye)
 OSType: linux
 Architecture: x86_64
 CPUs: 2
 Total Memory: 15.09GiB
 Name: vault
 ID: XYEL:LB5P:7J37:KMF7:LPRT:O52H:5XXL:EGBE:V2ZW:7KUB:GBE7:NJLX
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  127.0.0.0/8
 Live Restore Enabled: false

Additional Info

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions