Blob


1 => / Home
2 => /gmid.1.txt docs
4 # Contrib
6 This directory is for additional contributed files which may be useful.
8 ## Dockerfile
10 => https://git.omarpolo.com/gmid/tree/contrib/Dockerfile contrib/Dockerfile
12 A sample Dockerfile. The resulting image is a classic alpine linux image with a statically linked gmid installed as /bin/gmid.
13 To build the image:
15 ```instructions to build the image
16 # docker build -f contrib/Dockerfile -t gmid .
17 ```
19 and then run it with something along the lines of:
21 ```instruction to run the image
22 # docker run --rm -it -p 1965:1965 \
23 -v gmid.conf:/etc/gmid.conf:ro \
24 -v path/to/keys:/tls:ro \
25 -v /var/gemini:/var/gemini:ro \
26 gmid -c /etc/gmid.conf
27 ```
29 ## gencert
31 => https://git.omarpolo.com/gmid/tree/contrib/gencert contrib/gencert
33 contrib/gencert is a simple script to generate self-signed certificates.
35 ## OpenBSD rc file
37 => https://git.omarpolo.com/gmid/tree/contrib/gmid contrib/gmid
39 contrib/gmid is a sample service file for OpenBSD rc(8). To install it:
41 ```command to install the rc file
42 # cp contrib/gmid /etc/rc.d
43 ```
45 then the usual ‘rcctl [start|stop|enable|restart] gmid’ are available.
47 ## Systemd unit file
49 => https://git.omarpolo.com/gmid/tree/contrib/gmid.service gmid.service
51 A simple service file for systemd. To install it
53 ```instructions to install the system file
54 # cp contrib/gmid.service /lib/systemd/system/gmid.service
55 ```
57 then the usual ‘systemctl [status|start|enable|stop] gmid’ commands can be used to manage the server.
59 Some things to keep in mind:
60 * the ExecStart path may depend on the installation
61 * a ‘gmid’ user needs to be create for e.g. with
63 ```how to create a dedicated user
64 # useradd --system --no-create-home -s /bin/nologin -c "gmid Gemini server" gmid
65 ```
67 * logs can be inspected with journalctl(1)
69 ```reads gmid logs with journalctl
70 # journalctl -t gmid
71 ```
73 ## Vim syntax files
75 => https://git.omarpolo.com/gmid/tree/contrib/vim contrib/vim
77 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.:
79 ```install the vim syntax highlight in your home
80 $ mkdir -p ~/.vim
81 $ cp -R contrib/vim/* ~/.vim/
82 ```
84 To enable Syntastic checker, add to your vimrc:
86 ```
87 let g:syntastic_gmid_checkers = ['gmid']
88 ```
90 => vim-screenshot.png Screenshot of vim editing gmid.conf