đŸ’Ÿ Archived View for gmid.omarpolo.com â€ș contrib.gmi captured on 2024-05-12 at 14:51:39. Gemini links have been rewritten to link to archived content

View Raw

More Information

âŹ…ïž Previous capture (2024-02-05)

-=-=-=-=-=-=-

home

changelog

guide

faq

contributed files

This directory is for additional contributed files which may be useful.

Dockerfile

contrib/Dockerfile

A sample Dockerfile that builds an alpine linux-based image. To build the image:

# docker build -f contrib/Dockerfile -t gmid .

and then run it with something along the lines of:

# docker run --rm -it -p 1965:1965 \
        -v /var/gemini:/path/to/gemini/root:ro \
	gmid

By default a sample config that serves the content of /var/gemini using a self-signed certificate is included.

gencert

contrib/gencert

contrib/gencert is a simple script to generate self-signed certificates.

systemd unit file

contrib/gmid.service

contrib/gmid.sysusers

A simple service file for systemd. To install it

# cp contrib/gmid.service /etc/systemd/system/gmid.service
# systemctl daemon-reload

then the usual ‘systemctl [status|start|enable|stop] gmid’ commands can be used to manage the server.

Some things to keep in mind:

# systemd-sysusers contrib/gmid.sysusers
 or
# useradd --system --no-create-home -s /bin/nologin -c "gmid Gemini server" gmid
# journalctl -t gmid

mime.types

contrib/mime.types

A copy of OpenBSD' /usr/share/misc/mime.types to be used as

# /etc/gmid.conf

types {
	include "/path/to/mime.types"
}

renew certificates automatically

contrib/renew-certs

contrib/renew-certs is a script meant to be run in a crontab that watch for certificate expiration. It can optionally renew the certs and restart gmid too.

Read the documentation with: perldoc renew-certs

vim syntax files

contrib/vim

contrib/vim contains a syntax highlighting for vim. To install it, just copy the files to ~/.vim or to /usr/share/vim/vimfiles, e.g.:

$ mkdir -p ~/.vim
$ cp -R contrib/vim/* ~/.vim/

To enable Syntastic checker, add to your vimrc:

let g:syntastic_gmid_checkers = ['gmid']

Obligatory screenshot:

Screenshot of vim editing gmid.conf