An optimized VNC setup for Ona Environments. It's based on Ubuntu 24.04 with an XFCE desktop, KasmVNC server, and Google Chrome preinstalled. It also has IntelliJ Idea if you want to run that. It is tailored for Ona workflows that need a lightweight yet complete remote desktop accessible from any modern browser.
- Ubuntu 24.04 base image wrapped in the devcontainers/base toolchain
- KasmVNC server configured on port 5901 with WebSocket access
- XFCE desktop session launched through
vncserver - Google Chrome available system-wide (also aliased to
chromiumfor compatibility) - IntelliJ Idea (on-demand)
- Docker-in-Docker feature enabled so Docker CLI commands work inside the container
Click the button below to start your environment:
Then open port 5901 from the "Environment" tab in Ona. You can also launch your env in VSCode (desktop client) for localhost port forwarding and then open the 5091 port from the PORTS tab in VSCode.
Note: You can also fork this repository or copy the .devcontainer folder to your own repo.
- Display: DISPLAY variable defaults to
:1inside the container - Session: XFCE (
xfce4-session) is started via~/.xinitrc - VNC password: stored in
~/.kasmpasswd, set to123456 - Config: Additional KasmVNC settings live in
~/.vnc/kasmvnc.yaml
- Installed via Google-provided
.deb - Symlinked to
/usr/bin/chromiumso tools expecting Chromium also work - Chrome first-run and default-browser prompts are disabled for better automation
- Qt WebEngine sandbox is disabled via
QTWEBENGINE_DISABLE_SANDBOX=1
The container is privileged and mounts the host Docker socket. Inside the dev container you can run Docker CLI commands against the host daemon. Be mindful that changes affect the host Docker runtime.
- Use the integrated XFCE terminal (
xfce4-terminal) or VS Code terminal for shell work - Launch Chrome from the panel or the terminal (
google-chromeorchromium) - If you need to restart VNC:
sudo service dbus startthenvncserver -kill :1 && vncserver -disableBasicAuth -alwaysshared
- Cannot connect to VNC: Confirm port 5901 is forwarded and VNC server is running (
vncserver -list). Restart the VNC server with the command above. - Chrome rendering issues: Ensure
/dev/shmhas sufficient space; this container sets--shm-size=2gbto avoid crashes. - Docker commands fail: Verify the host Docker socket is mounted and your host user has permission to access it.