Run your Gemini server on Guix with Agate

=> Comment on Mastodon

Introduction

This article is about deploying the Gemini server agate on the Guix linux distribution.

=> Gemini quickstart to explain Gemini to beginners | Guix website

Configuration

=> Guix manual about web services, search for Agate.

Add the agate-service definition in your /etc/config.scm file, we will store the Gemini content in /srv/gemini/content and store the certificate and its private key in the upper directory.

(service agate-service-type
         (agate-configuration
          (content "/srv/gemini/content")
          (cert "/srv/gemini/cert.pem")
          (key "/srv/gemini/key.rsa"))

If you have something like %desktop-services or %base-services, you need to wrap the services list a list using "list" function and add the %something-services to that list using the function "append" like this.

(services
  (append
    (list (service openssh-service-type)
          (service agate-service-type
                   (agate-configuration
                    (content "/srv/gemini/content")
                    (cert "/srv/gemini/cert.pem")
                    (key "/srv/gemini/key.rsa"))))
    %desktop-services))

Generating the certificate

openssl req -x509 -newkey rsa:4096 -keyout key.rsa -out cert.pem -days 3650 -nodes -subj "/CN=YOUR_DOMAIN.TLD"

Conclusion

You are now ready to publish content on Gemini by adding files in /srv/gemini/content , enjoy!

Proxy Information
Original URL
gemini://perso.pw/blog//articles/guix-gemini.gmi
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
138.873286 milliseconds
Gemini-to-HTML Time
0.422683 milliseconds

This content has been proxied by September (ba2dc).