Docker Community Forums

Share and learn in the Docker community.

Docker osx /var/run/docker.sock file missing

(Pregmatch) #1

I am running boo2docker on Osx. I need api for my project but for some reason I got empty response for any request: returns empty json file.
This is my export:


from boot2docker shell:

export DOCKER_HOST=tcp://
export DOCKER_CERT_PATH=/Users/johnny/.boot2docker/certs/boot2docker-vm

I have lot of images on docker images:

debian                latest              479215127fa7        13 days ago         84.99 MB
debian                wheezy              479215127fa7        13 days ago         84.99 MB
postgres              9.4-rc1             d8c1fb73883a        7 weeks ago         214.3 MB
postgres              9.4-beta3           3edc3fed055f        9 weeks ago         214 MB

One more thing /var/run/docker.sock file does not exists (sudo find / -name docker.sock return nothing).
So when I do echo -e “GET /images/json HTTP/1.0\r\n” | nc -U /var/run/docker.sock nothing is returned.

boot2docker config gives me this

# boot2docker profile filename: /Users/johnny/.boot2docker/profile
Init = false
Verbose = false
Driver = "virtualbox"
Clobber = true
ForceUpgradeDownload = false
SSH = "ssh"
SSHGen = "ssh-keygen"
SSHKey = "/Users/johnny/.ssh/id_boot2docker"
VM = "boot2docker-vm"
Dir = "/Users/johnny/.boot2docker"
ISO = "/Users/johnny/.boot2docker/boot2docker.iso"
DiskSize = 20000
Memory = 2048
SSHPort = 2022
DockerPort = 0
HostIP = ""
NetMask = [255, 255, 255, 0]
LowerIP = ""
UpperIP = ""
DHCPEnabled = true
Serial = false
SerialFile = "/Users/johnny/.boot2docker/boot2docker-vm.sock"
Waittime = 300
Retries = 75

/Users/johnny/.boot2docker/boot2docker-vm.sock is also empty.
Can anyone help me with this?

UPDATE: funny thing when I run tobegit3hub/seagull i can see all containers and images.

Boot2Docker searching for docker-bootstrap.sock which does not exist
(Sven Dowideit) #2

/var/run/docker.sock will not be on your OSX filesystem - the Docker daemon is running inside the boot2docker VM - and that’s where the unix socket is.

That serial file is also not related to the docker socket.

oyu need to talk to the TCP socket specified in the DOCKER_HOST env.

(Pregmatch) #3

My question was: Why is returns empty json file when I have running containers?

I can see in boot2docker ssh docker.log this: http: TLS handshake error from tls: first record does not look like a TLS handshake

(Sven Dowideit) #4

it sounds to me like you’re not getting an empty json response, you’re getting an error because the client and server are not talking to each other.