Running docker container with SSH from cygwin screen does not work

I am running the docker toolbar installed on my computer running Windows 7, I am trying to access the docker from outside (win desktop) so that I can work with the graphical interface (let's say we will test using Firefox) As you know, dockers- dockers come with server X, so I found a solution to install xcygwin to perform X11 tasks ... and then run the container via ssh so that it can appear in my windows ... The problem is that I can not configure the display on the right, I:

export DISPLAY=:0.0 

And I tried several other parameters, such as export to host IP address, export to localhost, etc. then I SSH to my docker by running

docker-machine ssh default -X 

(-X should activate x11 forwarding if I'm not mistaken)

Now I get into my docker, so I'm just trying to launch my magic firefox container by running something like this:

Docker run --rm -e DISPLAY=$DISPLAY devurandom/firefox 

I get as expected Error: the screen does not open: That's right! I did not install the display in my docker! so i did:

DOCKER=0.0

Hm is always the same, cannot open the display: 0.0!

I also tried this one, which I could not understand where the Way comes from, but well.

docker run -ti -v / tmp / serverX: / tmp / ServerX -e DISPLAY = $ DISPLAY ...

No luck, someone knows how to fix this plz!

+4
source share

Source: https://habr.com/ru/post/1664700/


All Articles