CGI is dead. Long Live CGI
CGI is alive and kicking on the #geminiProtocol, for sure.
So as you can imagine, when I stumbled across Gemini around January of 2022, I was very surprised to see that a lot of the servers being created for people to use had CGI support for creating dynamic content. At first I was baffled, but it really does make a lot of sense for a text-focused protocol such as Gemini:
- Most capsules are low traffic so spinning up these processes, while resource intensive by today's standards, aren't really too much of an issue for Gemini
- Gemini is purposely limited, and as such, things like AJAX calls to a Gemini server just aren't supported
- CGI has been around for a while, and is fairly accessible to professional and hobby coders alike
I think the beauty of CGI scripts is that it lowers the barrier for novice programmers to make an interactive capsule (gemini site) and practice their coding skills. Want to make an old school guestbook using Bash scripts and SQLite? Go for it! Want to make a commenting system using Python? Sure. No problem. It's the simplicity that I like, which is core to the theme of Gemini.
Documentation, however, on how to make a CGI script specifically for Gemini was lacking, so I ended up making my own HOWTOs on doing that. I even convinced Solderpunk to put a link on their official Gemini FAQ that goes over creating your own capsule and introducing you to CGI programming.
Again, if you have a Gemini browser – like LaGrange – you can see my HOWTO here: gemini://gemini.smallweb.space/HOWTO/managing-your-own-capsule.gmi