Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/praetoriansentry/melchior
Simple, secure, static file server for the Gemini protocol
https://github.com/praetoriansentry/melchior
gemini gemini-protocol server
Last synced: 3 months ago
JSON representation
Simple, secure, static file server for the Gemini protocol
- Host: GitHub
- URL: https://github.com/praetoriansentry/melchior
- Owner: praetoriansentry
- License: apache-2.0
- Created: 2020-10-28T00:39:21.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2020-11-14T23:46:36.000Z (about 4 years ago)
- Last Synced: 2024-06-20T09:15:09.226Z (8 months ago)
- Topics: gemini, gemini-protocol, server
- Language: Go
- Homepage:
- Size: 19.5 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.org
- License: LICENSE
Awesome Lists containing this project
README
* Melchior
This is meant to be an extremely simple static file server that
operates on the gemini protocol. I mostly just wanted an extremely
simple and hopfully secure server to run at home.** Features
- Configured with environment variables
** Running
In order to run this, at the very least you'll need to generate a
certificate. I've been using a command like this.#+BEGIN_SRC
openssl req -newkey rsa:2048 -nodes -keyout localhost.key -nodes -x509 -out localhost.crt -subj "/CN=localhost"
#+END_SRCAfter getting the certificates generated you can run this by doing
#+BEGIN_SRC
env MELCHIOR_TLS_CERT=localhost.crt MELCHIOR_TLS_KEY=localhost.key MELCHIOR_HOSTNAME=localhost MELCHIOR_BIND_ADDR=127.0.0.1:1965 MELCHIOR_ROOT_DIR=. go run melchior.go
#+END_SRCIf you don't have a gemini client handy, you can use ~socat~ to do
some testing
#+BEGIN_SRC
socat - OPENSSL-connect:127.0.0.1:1965,verify=0
#+END_SRC** Installation
#+begin_src
# I'm doing a static build so that I can run this more easily in a container-ish environment
go build -ldflags "-linkmode external -extldflags -static" -a melchior.go
cp melchior /usr/local/bin/melchior
cp melchior-daemon.service /etc/systemd/system/melchior-daemon.service
chmod 664 /etc/systemd/system/melchior-daemon.servicesudo systemctl enable melchior-daemon
sudo systemctl start melchior-daemon
#+end_src