A gemini protocol server in Common Lisp
  • Common Lisp 100%
Find a file
2022-02-28 09:25:15 -05:00
.gitignore Don't use trivial-file-size, since we're already using osicat 2020-07-15 14:04:09 -04:00
classes.lisp Move closing the stream into write-response 2021-11-12 21:16:52 -05:00
germinal.asd Merge branch 'master' of carcosa.net:jmcbray/germinal 2021-03-31 11:21:09 -04:00
germinal.ros Rename blacklist to blocklist because I'm a blockhead 2021-11-12 21:18:39 -05:00
germinal.service Add more systemd hardening to example unit file 2022-02-28 09:20:52 -05:00
LICENSE.md Add project files 2019-06-23 16:45:31 -04:00
middleware.lisp Add a middleware for handling 'gone' URLs 2021-11-11 16:53:05 -05:00
package.lisp Rename blacklist to blocklist because I'm a blockhead 2021-11-12 21:18:39 -05:00
README.org Fix code highlighting in readme 2021-03-09 13:55:34 -05:00
server.lisp Make file listings gmisub compatible 2021-11-29 21:27:46 -05:00
util.lisp Don't use trivial-file-size, since we're already using osicat 2020-07-15 14:04:09 -04:00

Germinal, a Gemini Protocol server

Germinal is a server for the Gemini Protocol, written in Common Lisp.

It is named after the early 20th century Yiddish-language anarchist newspaper Germinal. I wanted to name it after an anarchist publication to convey the idea of people sharing information and ideas with each other, in contrast to the way the web is used to push advertising from corporations to people. And it happened that Germinal shares some sounds with Gemini.

Features

Current

  • Serves any type of document with an appropriate mime type.
  • Serves .gmi files as text/gemini, the gemini mapfile format.
  • Serves index.gmi as a directory listing, if it exists
  • Serves a simple directory listing for directories without index.gml
  • Serves only world-readable content, much like Gophernicus.
  • Configuration in Lisp, including routes and middleware
  • Handle defined routes with custom Lisp functions
  • Add middleware to add side-effects (like logging) to every request.

Planned

  • More example handlers and middleware functions
  • Keep up to date with any specification changes/clarifications.

Maybe

  • authentication by client certificate
  • cgi-bin support

Installation

With Roswell

  1. Install Roswell.
  2. Put the Germinal sources in a folder that Common Lisp knows about; usually, either ~/common-lisp/, or ~/.roswell/local-projects/. You can just put a symbolic link to the folder containing the sources into either of those directories.
  3. Edit germinal.ros, setting the configuration variables to what's appropriate for your server. In particular, you'll want to use gemcert to generate keys for your domain, and set your domain name and the path to the keys in germinal.ros. If you don't want to run a swank (debugging) server on localhost, you'll want to comment out the lines that start it.
  4. Run germinal.ros. For production deployment, you'll probably want to create a user such as germinal for Germinal to run as. They'll need to own their home directory, and to run ros setup before you run germinal.ros as them. They'll also need the Germinal sources symlinked into someplace Roswell can find it, as above.

The germinal.service file is a pretty typical systemd configuration for running Germinal from Roswell.

Manually

Germinal doesn't depend on Roswell; you can start it up any old way, as long as you have all the dependencies installed (generally with quicklisp). You can write a script to start it with sbcl -load or whatever you like; it just has to set the configuration variables and run germinal:start.