RLGWebD
Find a file
John "Elwin" Edwards 9004afebdc Terminal emulation: implement the CSI b sequence.
CSI b repeats the previous character, if it was printable and not an
escape sequence.
2019-09-05 15:19:27 -04:00
about.html Update the documentation, removing the betas. 2015-01-24 10:18:26 -05:00
bell.svg Put this project under version control, finally. 2012-05-06 08:45:40 -07:00
dglwatcher.c Rename watcher to dglwatcher. 2015-01-07 13:49:37 -05:00
index-sh.html Use SVG for the bell icon instead of PNG. 2013-10-31 20:44:35 -07:00
index.html Update the documentation, removing the betas. 2015-01-24 10:18:26 -05:00
initscript Move the NODE_PATH location. 2017-12-26 13:23:55 -05:00
Makefile Fix syntax error in Makefile. 2017-01-12 19:02:20 -05:00
options.html Options-related UI improvements. 2012-09-12 16:03:09 -07:00
options.js Options-related UI improvements. 2012-09-12 16:03:09 -07:00
README.txt Changes for compatibility with recent versions of NodeJS. 2019-08-25 21:27:31 -04:00
rlgterm.js Initial support for TLS. 2017-01-01 20:18:01 -05:00
rlgwebd Changes for compatibility with recent versions of NodeJS. 2019-08-25 21:27:31 -04:00
rlgwebd-stop Fix possibly insecure permissions on the control socket. 2017-01-28 09:57:31 -05:00
rlgwebd.conf Fix possibly insecure permissions on the control socket. 2017-01-28 09:57:31 -05:00
rlgwebd.service Move the NODE_PATH location. 2017-12-26 13:23:55 -05:00
shterm.js WebTTY: remove polling. 2014-01-27 16:02:27 -08:00
sqlickrypt.c Increase max username length to 20. 2014-03-30 20:42:48 -07:00
style-rlg.css Options-related UI improvements. 2012-09-12 16:03:09 -07:00
termemu-keys.js Improve the probability of detecting numpad 5. 2012-08-12 08:22:55 -07:00
termemu.js Terminal emulation: implement the CSI b sequence. 2019-09-05 15:19:27 -04:00
tty.css Improvements to the keyboard. 2012-06-23 17:11:51 -07:00
webtty Change various filenames. 2016-01-14 20:52:29 -05:00

                        =====   RLGWebD   =====

RLGWebD is a node.js app that enables playing roguelike games in the 
browser.  It is intended to be compatible with dgamelaunch.

Node
---
RLGWebD is currently being updated to work with Node v10.x.

It requires the 'posix', 'node-pty', and 'websocket' modules.  Currently,
it expects them to be installed in "/var/local/lib/node_modules".  It
is not recommended to run npm as root when installing the modules.

init
---
RLGWebD now includes a systemd unit file, which is the recommended way
to run it.  See below for more instructions.

For other init systems, a shell script is provided.  This is not really
a proper initscript, but it could form the basis of one.

Configuration
---
A configuration file is installed at /etc/rlgwebd.conf.  It contains a
list of options.

If the domain_name option and the SSL-related options are set, rlgwebd
will use HTTPS instead of insecure HTTP.

If you change the chroot location, change it in the first line of the 
Makefile too.

Installation
---
RLGWebD expects to be run in a chroot used by dgamelaunch, and it makes 
some assumptions about the configuration.  It expects the dgamelaunch 
playground to be at /dgldir inside the chroot.  It expects the 
in-progress files to be in /dgldir/inprogress/<gamename>.  RLGWebD 
creates in-progress files in those locations, and dgamelaunch must be 
patched to prevent it from deleting them.

It needs the devpts filesystem mounted inside the chroot.  This can be 
done with a line in /etc/fstab like the following:
	devpts	CHROOT/dev/pts	devpts	newinstance,ptmxmode=666 0 0

RLGWebD uses two separate programs written in C.  sqlickrypt operates
on the dgamelaunch user database.  dglwatcher monitors the inprogress
directories.  Run "make" to build both of them.

sqlickrypt needs /dev/urandom to exist in the chroot.  Run as root:
	mknod CHROOT/dev/urandom c 1 9

Running "make install" will:
  Copy the Web assets into the chroot
  Copy the C programs and the libraries they need into the chroot
  Install the main RLGWebD script in /usr/local/bin
  Place the systemd unit file in the proper directory
  Copy a configuration file into /etc

If you don't use systemd, or want to change the installation locations,
you will have to edit the Makefile.

You will still need to run "systemctl enable rlgwebd" to make the 
server start on boot, and "systemctl start rlgwebd" to make it start
immediately.

Starting and stopping RLGWebD
---
If you are using systemd, "systemctl start" and "systemctl stop" should
work as with any other service.

If you are using the initscript, running it with no arguments will 
start RLGWebD.  Stop by running it with 'stop' as an argument.  (This 
requires socat to be installed.)

webtty
---
"webtty" is a Node app which uses the terminal emulator to run a shell.  It
includes NO SECURITY WHATSOEVER and should only be used for testing the 
terminal emulator.  Copy index-sh.html to index.html before running it.

Copyright status
---
All files in this project are in the public domain.