Created
November 8, 2016 20:15
-
-
Save runcom/5118b48bba4051a2db6090c5b4fd2475 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cid=$(docker run -d busybox top) | |
$ docker exec -d $cid sleep 10000 | |
$ execid=$(docker inspect $cid | jq -r '.[0].ExecIDs[0]') | |
$ echo -e "GET /exec/$execid/json HTTP/1.0\r\n" | nc -U /var/run/docker.sock | grep Pid || false |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment