Blob


1 # Frequently Asked Questions
3 ## How can I report a bug, suggest a feature or send a patch?
5 Just drop an email to <gmid [at] omarpolo [dot] com> or open an issue/pull request on Codeberg or Github.
7 => https://codeberg.org/op/gmid Codeberg mirror
8 => https://github.com/omar-polo/gmid GitHub mirror
10 When reporting a bug please include the relevant information to reproduce the issue you're facing: your configuration file, the gmid version, and your operating system or distro at least.
13 ## How can I define the right MIME types for my files?
15 gmid, like many other servers, uses a list of known file extensions to decide what MIME type use. A few of them are built-in for convenience but it's quite easy to add custom ones:
17 ``` example of how to use the type rule in the configuration file
18 types {
19 application/postscript ps eps ai
20 application/rss+xml rss
22 # it's also possible to just include a file here
23 include "/usr/share/misc/mime.types"
24 }
25 ```
28 ## How to run CGI scripts?
30 As of gmid 2.0, to run CGI scripts an external program like fcgiwrap or slowcgi are needed.
32 From the gmid side, one `fastcgi' block needs to be defined with the `socket' pointing at the fcgiwrap or slowcgi socket inside the chroot. The `SCRIPT_NAME' parameter pointing to the script path is often needed since gmid is unable to deduce the right path otherwise.
34 ``` example configuration that runs a CGI via slowcgi
35 server "example.com" {
36 listen on *
37 cert "/path/to/cert"
38 key "/path/to/key"
40 location "/cgi-bin/hello" {
41 fastcgi {
42 socket "/run/slowcgi.sock"
43 param SCRIPT_NAME = "/cgi-bin/hello"
44 }
45 }
46 }
47 ```
49 Then, fcgiwrap or slowcgi need to be started as well.
52 ## How to automatically renew the certificates?
54 It depends on how the certificate were obtained. For example, if acme-client or certbot are used they provide their own mechanism to renew the certs and restart daemons.
56 In case of a self-signed certificate, contrib/renew-certs could help. It's meant to be scheduled periodically with cron(8) and automatically generate a new key and certificate when one is about to expire and restarts gmid.
58 => TREE/contrib/renew-certs contrib/renew-certs