References to "localhost" broken when using Docker on Windows (through VirtualBox)
See original GitHub issueWhen working with Docker on Windows, with VirtualBox as a back-end, Docker creates a virtual machine (boot2docker linux image) with its own IP address, and runs the Docker containers on that. However those ports are not mapped to the local (Windows) host machine. So references to https://localhost
don’t resolve properly to the running Blockstack tools. Instead, if in a Dockerized environment like that, they need to be able to be configured, to set the IP address of the running boot2docker VM (something like 192.168.99.100).
Issue Analytics
- State:
- Created 6 years ago
- Comments:20 (11 by maintainers)
Top Results From Across the Web
References to "localhost" broken when using Docker on ...
docker ps shows that the container is forwarding port 8888, but looking at the VirtualBox settings for the one running Boot2Docker machine, it ......
Read more >Docker localhost process not working on Windows
I'm assuming you're using VirtualBox, since that's what is integrated with the Quickstart terminal. The reason it doesn't work is that ...
Read more >Install Docker on Windows (WSL) without Docker Desktop
With Docker Desktop's WSL 2 backend, Docker integrates with Windows in a fairly elegant way, and the docker client can be launched from...
Read more >Frequently asked questions for Windows
Yes, you can run VirtualBox along with Docker Desktop if you have enabled the Windows Hypervisor Platform feature on your machine.
Read more >Running Docker containers on Bash on Windows - Jayway
Running Docker directly on Bash on Windows is not supported, but this post shows how you can run the engine on Windows and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Trying v0.17 now… looks like installing and starting is working better than yesterday:
8147ed9f3210: Pull complete adf24d70b9bf: Pull complete 08ac07a33362: Pull complete 7603a6b7bdde: Pull complete f17c2b896e3d: Pull complete def9d545d15c: Pull complete
Now let’s see… it’s working! So with 0.17.x it’s working now!
Okay – our
start.sh
script attempts to set up a network bridge to the docker virtualmachine on ports6270
,8888
, and1337
– it seems like this is failing if the docker virtualmachine already existed. The offending lines of code are over in our packaging repo:https://github.com/blockstack/packaging/blob/master/blockstack-toolbox-windows/windows/start.sh#L50
I’ll work on this tomorrow – should be easy enough to use vboxmanage to check if the port forwarding is set up on the virtualmachine, and if not, set it up.
Thanks for finding this!