x11 forwarding to docker image without --net=host is possible?

72 Views Asked by At

I am currently trying to set up X11 forwarding to a Docker image. However, I believe that using the --net=host option is necessary for this. My current command includes:

--net=host \
-it -p 34522:22 -p 34566:6006 -p 34588:8888 -p 34589:8889 \

My concern is that the --net=host option seems to override the port forwarding settings specified by -it -p 34522:22 -p 34566:6006 -p 34588:8888 -p 34589:8889.

Is there a way to enable X11 forwarding in Docker while maintaining these port forwarding settings? Or, alternatively, is there a method to achieve X11 forwarding without the --net=host option, using the given port mappings?

0

There are 0 best solutions below