Paperwindow is one of the ways we give back to the open source community.
Host desktop software on your server and stream it to anything that has a web browser.
Paperwindow uses Xpra to stream content, Supervisord to manage processes, Fluxbox as a window manager, and Wine for running Windows apps when necessary. Pulseaudio is used to grab and stream audio. Most stuff runs inside Docker/X11Docker.
Everything you need to know about using Paperwindow.
If you don't need GPU acceleration, you only need these dependencies.
$ sudo apt-get install xvfb xserver-xephyr xorg pulseaudio
Otherwise you additionally need any related GPU drivers (as well as weston, xwayland, and xdotools)
This is a base Docker image. Fork/clone it and add something to run in the app
directory. This directory should contain all assets, and a launcher called either launcher.sh
(for standard Linux apps) or launcher.exe
(for Windows apps).
The Makefile
should serve as a template for usage of Paperwindow. Keep in mind that Paperwindow does do automatic scaling, but fullscreen apps sometimes have strange behavior with this.
Check run1080p-ssl
in the Makefile
for the base command for SSL. The certificate to use should be named cert.pem
and placed in the current working directory (symlinks should also work).
By default, Paperwindow serves the Xpra HTML5 client. However, you can always connect your own external modified client to it.
Deploying Paperwindow is a bit of a process. Let's take a look at a possible implementation process here.
- Set up a fleet of Linux servers (preferably with Debian-based distros). This is pretty obvious. If you're serving graphics-intensive apps, make sure these servers are able to access a GPU.
- Install dependencies (see the Dependencies section above).
- Download Paperwindow on a server, as well as your app.
- Build the Paperwindow container and push it to a private package repository. If your fleet is small, you could get away with building the container on each server individually (this also involves doing step 3 repeatedly)
- Download Paperwindow on all other servers.
- Set up SSL on each server if needed (try certbot for this).
- Set up a way to pull up Paperwindow on-demand. This means: swapping out data and launching the server.
- Set up a central web UI that allows users to run on-demand launching. It should embed the webserver served by Paperwindow when the app is active. (You can use standard Xpra URL parameters, like
?floating_menu=false
. See https://github.com/Xpra-org/xpra-html5/blob/master/docs/Configuration.md).
Paperwindow is based off of some of the open source work of Kyle Anderson. It was modified by Cedric Kim for optimized use at Geschafft, and eventually we open-sourced our version to give back to the community.
(May look strange on smaller screens)
_ __
____ ____ _____ ___ ______ __(_)___ ____/ /___ _ __
/ __ \/ __ `/ __ \/ _ \/ ___/ | /| / / / __ \/ __ / __ \ | /| / /
/ /_/ / /_/ / /_/ / __/ / | |/ |/ / / / / / /_/ / /_/ / |/ |/ /
/ .___/\__,_/ .___/\___/_/ |__/|__/_/_/ /_/\__,_/\____/|__/|__/
/_/ /_/
More ASCII art in asciiart.txt :)