How to run a X Windows application in Codenvy Cloud IDE?

821 Views Asked by At

Copdenvy's shellinabox runner allows you to start a shell in the browser in which you can compile and run your code. This is fine for applications that are console based. Is it possible to run an X Windows application in the cloud and see the graphical window?

Setting the DISPLAY variable in the shell to that of your Linux workstation could work, though it relies on you being in control of the local network for things like NAT and firewall settings. The attraction of the cloud IDE is that you only need a browser and an https connection.

Can you ssh -X into the Docker container from an X capable source? Where would you find the URL? How would you manage the ssh keys?

1

There are 1 best solutions below

1
On

If you look at the Java/Swing "VNC + Java 7" runner for example you'll see that you're able to run an application which is using X DISPLAY through VNC. Codenvy supplies a web based X Windows environment that you can access by clicking on the hyperlink that is shown underneath the Console window, to the left of the Timeout counter. You can then look at the Docker recipe used to start this sample.

SSH in the docker container could be managed in Codenvy 3.x if you install inside the VM the sshd daemon and export the ssh/22 port. In upcoming Codenvy SaaS 4.x ssh will be enabled without any configuration.