1

OK so here is what I have done so far. I installed docker for mac, and that worked fine. From there I tried to get a project up and running using docker-compose and I got the following error:

Could not read CA certificate "/Users/<useraccountfolder>/.boot2docker/certs/boot2docker-vm/ca.pem": open /Users/<useraccountfolder>/.boot2docker/certs/boot2docker-vm/ca.pem: no such file or directory

So I tried to fix it by trying this accepted answer. This is when I got another error, Host does not exist: “default”. This is when I trie this accepted answer, but when I tried to run docker-machine create default, I got this error: Error with pre-create check: "VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path". I am just lost at this point. Any help?

Community
  • 1
  • 1
Chaim Friedman
  • 6,124
  • 4
  • 33
  • 61

2 Answers2

0

To use docker machine you need the latest version of VirtualBox, from the docker docs:

IF YOU ARE USING DOCKER FOR MAC

Docker for Mac uses HyperKit, a lightweight macOS virtualization solution built on top of the Hypervisor.framework in macOS 10.10 Yosemite and higher.

Currently, there is no docker-machine create driver for HyperKit, so you will use virtualbox driver to create local machines. (See the Docker Machine driver for Oracle VirtualBox.) Note that you can run both HyperKit and Oracle VirtualBox on the same system. To learn more, see Docker for Mac vs. Docker Toolbox.

Make sure you have the latest VirtualBox correctly installed on your system (either as part of an earlier Toolbox install, or manual install).

Source: https://docs.docker.com/machine/get-started/#prerequisite-information

Frenus
  • 780
  • 5
  • 13
  • https://docs.docker.com/docker-for-mac/docker-toolbox/#the-docker-for-mac-environment it would seem that docker for mac does not need virtualbox. – Chaim Friedman Apr 26 '17 at 14:26
  • Did you install Docker for Mac, or Docker Toolbox? You said that you installed Docker for Mac, which doesn't include VirtualBox. – Frenus Apr 26 '17 at 14:29
  • I installed docker for mac which based on my understanding doesn't need virtualbox. – Chaim Friedman Apr 26 '17 at 14:30
  • Docker for mac doesn't need VirtualBox, but docker-machine does for OSX. Since you used `docker-machine create default` you need to have VirtualBox installed as stated in https://docs.docker.com/machine/get-started/#prerequisite-information. – Frenus Apr 26 '17 at 14:40
  • I only ran that command to fox the issue of host does not exist. There needs to be way to fix this issue without virtualbox. – Chaim Friedman Apr 26 '17 at 14:41
  • In your question you said you were stuck on `Error with pre-create check: "VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path"`. Installing VirtualBox fixes this error. Maybe you can post your docker-compose so we can try to fix it without VirtualBox? – Frenus Apr 26 '17 at 14:45
0

OK so I found a solution which is probably not fixing the root issue, but it does work. To unset previous variables I ran this command unset ${!DOCKER*}. This worked, but then I had to run it every time I started a new terminal session, so I added it to my .bash_profile and now I am good.

Chaim Friedman
  • 6,124
  • 4
  • 33
  • 61