You may also need to run: /f "tokens=*" %i IN ('"C:\ProgramData\chocolatey\lib\docker-machine\bin\docker-machine.exe" env') DO order to get Docker working properly. This allows the Docker client and Docker Compose to communicate with the Docker Engine running in the Linux VM that we named "default". Next, we need to set up Docker environment variables: docker-machine env default Start the virtual machine by running the following command in your terminal app: docker-machine start default Step 3: Setting up Environment Variables
In my case, I forgot about this and had to spend few days of head banging until I figured out why the heck was I getting a "Couldn't find package.json" error when trying to run the containers, built through this tutorial. If you don't mind to use the default settings, do not forget to put your project under the 'Users' directory, e.g. Select default VM and go to Settings > Shared Folders. To add a different path, simply go to the Oracle VM VirtualBox GUI. By default, you can only mount from the C://Users/ directory. We need to allow Docker to mount volumes located on your hard drive. This was the most critical detail that I forgot . You can do that by going to Oracle VM VirtualBox -> default virtual machine -> Settings -> Network -> Adapter 1 -> Port Forwarding. Next, we need to configure which ports are exposed when running Docker containers. This will create a docker virtual machine called 'default'. Open your favorite bash terminal app and run this: docker-machine create -driver virtualbox default
Then use Windows PowerShall and Chocolatey, your Windows package manager, to install a docker-machine by running the following: choco install docker-machine This way we can have a virtual machine which will be running Linux where our Docker will live. It gives you the ability to have multiple virtual machines installed on your physical one. Step 1: Installationsįirst you need to install a software called Oracle VM VirtualBox.
It explains that it is possible to use Docker in Windows 10 Home by leveraging a Linux virtual machine and having Docker containers running on it. And maybe I can save someone a few days of going back and forth to StackOverflow! ?Īfter some reading, I found this article. It worked for me, which make me want to share it with you.
ActionsĪfter defining what we want, let's see how to achieve it. The last one is a bit out of the scope of this article, but we should start from somewhere, no?.
We would like to have Docker running on the same machine so that we are able to create docker images, run containers, and learn better and grow faster! We have Windows 10 OS Home edition on our machine. What do we want to achieve and what do we currently have? ? Reasoningįirst, let's do a short summary of the situation. Which means that if you are like me and have just Windows 10 Home edition on your personal laptop, then you cannot use Docker… or maybe you still can. So far, so good.īut it turns out that the latest versions of Docker require Windows 10 Pro, Enterprise, or Education. Recently I have been watching a tutorial where, in order to follow it, you need to have Docker running on your machine.