Skip to content

Exec start kills daemon with nil reference #20638

@KostyaSha

Description

@KostyaSha

Full stacktrace: https://gist.github.com/KostyaSha/849a2f21e017b7099685
Piece of trace:

time="2016-02-23T23:24:49.983175708Z" level=debug msg="starting exec command 32872f2d97a44f6eb05f5051ba57ed4aebb6e44186dffd4e27165e97b6035d22 in container 9b8572202459e502251a08520102da2f17c2ec701279602b515a833b7468537c"
time="2016-02-23T23:24:49.985347690Z" level=debug msg="attach: stdin: begin"
time="2016-02-23T23:24:49.985669491Z" level=debug msg="Closing buffered stdin pipe"
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x20 pc=0x6b32e3]

docker-toolbox: 1.10.1-1.10.2
docker-version:

Client:
 Version:      1.10.2
 API version:  1.22
 Go version:   go1.5.3
 Git commit:   c3959b1
 Built:        Mon Feb 22 22:37:33 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.10.2
 API version:  1.22
 Go version:   go1.5.3
 Git commit:   c3959b1
 Built:        Mon Feb 22 22:37:33 2016
 OS/Arch:      linux/amd64

Localised example. Steps to reproduce:

  1. docker run -itd busybox cat
curl --cert cert.pem --key key.pem --cacert ca.pem \
 https://192.168.99.100:2376/containers/${CONTAINER_ID}/exec \
 -H "Content-Type: application/json" \
 -X POST \
 --data @exec.json

exec.json:

{
    "AttachStderr": true,
    "AttachStdin": true,
    "AttachStdout": true,
    "Cmd": [
        "/bin/bash",
        "-cxe",
        "cat << EOF > /tmp/config.sh.tmp && cd /tmp && mv config.sh.tmp config.sh\n sdf\nEOF\n"
    ]
}
curl --cert cert.pem --key key.pem --cacert ca.pem \
 https://192.168.99.100:2376/exec/${EXEC_ID}/start \
 -H "Content-Type: application/json" \
 -X POST \
 --data @start.json

start.json:

{
    "Detach": true,
    "Tty": true
}

Combination may be crazy, but i expect that daemon should survive.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugBugs are bugs. The cause may or may not be known at triage time so debugging may be needed.priority/P1Important: P1 issues are a top priority and a must-have for the next release.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions