💾 Archived View for caranatar.xyz › denoscuri.gmi captured on 2020-09-24 at 00:39:41. Gemini links have been rewritten to link to archived content
-=-=-=-=-=-=-
A simple Gemini[1] server written using Deno[2] and Typescript[3].
Create a configuration with one or more server blocks:
{ "servers": [ { "hostname": "host_one", "port": 5555, "certFile": "/var/gemini/certs/host_one_cert.pem", "keyFile": "/var/gemini/certs/host_one_key.pem", "documentRoot": "/var/gemini/host_one", "logFile": "/var/gemini/logs/host_one.log" }, { "hostname": "host_two", "certFile": "/var/gemini/certs/host_two_cert.pem", "keyFile": "/var/gemini/certs/host_two_key.pem", "documentRoot": "/var/gemini/host_two", "logFile": "/var/gemini/logs/host_two.log", "requireCRLF": false } ] }
port, requireCRLF, and logFile are optional configuration items, which will default to 1965, true, and ./<hostname>.log, respectively, if they are not present. All other options are required.
Requires installation of Deno[2].
Clone the repository, then run the following commands, substituting appropriate values for the allow-read and allow-write parameters and passing the path to your config file:
deno run --allow-net --allow-read=/var/gemini --allow-write=/var/gemini/logs denoscuri.ts /var/gemini/config.json
To fetch the latest version from master and run it:
deno run --allow-net --allow-read=/var/gemini --allow-write=/var/gemini/logs https://raw.githubusercontent.com/caranatar/denoscuri/master/denoscuri.ts /var/gemini/config.json
To fetch a tagged version (such as the current one):
deno run --allow-net --allow-read=/var/gemini --allow-write=/var/gemini/logs https://raw.githubusercontent.com/caranatar/denoscuri/v0.1.0/denoscuri.ts /var/gemini/config.json
"Denoscuri" is a portmanteau of Deno and Dioscuri - the Greek name for the twins Castor and Pollux, who became the constellation Gemini