How to share Mac screen to Linux docker container?

I want to run odesk time tracker (a Qt4 app) which captures your screen and keystrokes for freelance work logging. But I don’t trust it and want to sandbox it.

On Linux, there are ways to run GUI items on docker container and forward X11 to Linux host. Can I do this on mac? The app will run on Linux container and will be displayed on Mac with capturing screen/keystroke.

  • Multicast not being sent to all Docker containers
  • Dockerfile in a Amazon EB
  • How to setup a valid mongo replicaset
  • Shiny server inside Docker container reverse proxied with nginx will not follow 301 redirects
  • Docker error on an entrypoint script: “no such file or directory”
  • Installing novadocker for openstack
  • I think VNC method would display the linux host, not the mac. If linux connects mac, I have to install the software on mac. I don’t know if I can do X11 forwarding.

  • Lucee 5, Nginx, and Docker Compose not finding sample index.cfm file
  • Unable to mount persistent volume to Docker container using Rex-Ray and VirtualBox Media storage - “Invalid managed object reference” error
  • SSH to docker bridged instance
  • Docker Run Time Statistics ( Benchmarks)
  • Dockerize stack: MapServer - AngularJs web app - Lumen API - PostgreSQL
  • Creating a swarm cluster with Docker for Mac
  • One Solution collect form web for “How to share Mac screen to Linux docker container?”

    You need to have XQuartz installed on your Mac. You can get it here –

    Once you installed it, follow this procedure –

    1. Run X11 application (included with XQuartz)
    2. Open X11 Preferences and make sure “Allow connections…” is checked
      X11 Preferences
    3. Restart X11 application
    4. Open a terminal
    5. ssh to your docker with X11 forwarding: ssh -X YOUR_DOCKER_IP

    From now on, any GUI application that you run on your docker will show up on your Mac.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.