Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove bundled VNC server #84

Merged
merged 4 commits into from
Feb 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,6 @@ repos:
types: [file]
exclude: jupyter_remote_desktop_proxy/static/dist

# Content here is mostly copied from other locations, so lets not make
# formatting changes in it.
exclude: share

# pre-commit.ci config reference: https://pre-commit.ci/#configuration
ci:
autoupdate_schedule: monthly
21 changes: 15 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,16 @@ This is based on https://github.com/ryanlovett/nbnovnc.

When this extension is launched it will run a Linux desktop on the Jupyter single-user server, and proxy it to your browser using VNC via Jupyter.

If a `vncserver` executable is found in `PATH` it will be used, otherwise a bundled TightVNC server is run.
You can use this to install vncserver with support for other features, for example the [`Dockerfile`](./Dockerfile) in this repository installs TurboVNC for improved OpenGL support.
## VNC Server

This extension requires a [VNC Server](https://en.wikipedia.org/wiki/Virtual_Network_Computing)
to be installed on the system (likely, in the container image). The
most tested VNC server is [TigerVNC](https://tigervnc.org/), while
[TurboVNC](https://www.turbovnc.org/) also works. Any VNC server available
in `$PATH` as `vncserver` will be used, but no real testing outside of
these servers has been performed.

For an example, see the [`Dockerfile`](./Dockerfile) in this repository which installs TigerVNC and XFCE4.

## Installation

Expand All @@ -28,19 +36,20 @@ You can use this to install vncserver with support for other features, for examp
from [conda-forge](https://anaconda.org/conda-forge/websockify) or with
[apt](https://packages.ubuntu.com/search?suite=all&searchon=names&keywords=websockify)

3. Install the packages needed to provide the actual Linux Desktop environment.
You need to pick a desktop environment (there are many!) - here is the packages
you would need for using the light-weight [XFCE4](https://www.xfce.org/) desktop environment:
3. Install the packages needed to provide a VNC server and the actual Linux Desktop environment.
You need to pick a desktop environment (there are many!) - here are the packages
to use TigerVNC and the light-weight [XFCE4](https://www.xfce.org/) desktop environment on Ubuntu 22.04:

```
dbus-x11
libgl1-mesa-glx
xfce4
xfce4-panel
xfce4-session
xfce4-settings
xorg
xubuntu-icon-theme
tigervnc-standalone-server
tigervnc-xorg-extension
consideRatio marked this conversation as resolved.
Show resolved Hide resolved
```

The recommended way to install these is from your Linux system package manager
Expand Down
7 changes: 4 additions & 3 deletions jupyter_remote_desktop_proxy/setup_websockify.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,10 @@ def setup_websockify():
sockets_path = os.path.join(sockets_dir, 'vnc-socket')
vncserver = which('vncserver')

if vncserver is None:
# Use bundled tigervnc
vncserver = os.path.join(HERE, 'share/tigervnc/bin/vncserver')
if not vncserver:
raise RuntimeError(
"vncserver executable not found, please install a VNC server"
)

# TigerVNC provides the option to connect a Unix socket. TurboVNC does not.
# TurboVNC and TigerVNC share the same origin and both use a Perl script
Expand Down
Binary file removed jupyter_remote_desktop_proxy/share/tigervnc/bin/Xvnc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Loading