💾 Archived View for going-flying.com › how-built.gmi captured on 2023-03-20 at 17:29:27. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2023-01-29)
-=-=-=-=-=-=-
I hope it may be of some interest to someone, someday how the content in here is maintained. The funny thing is that in a lot of ways it is built extremely similarly to the HTTPS version of going-flying.com, which is to say it uses a git post-receive hook.
https://www.going-flying.com/blog/first-post-part-two.html
There are actually two parts here, part one is the git repository where all of the stuff I write by hand lives. This is deployed as described, by a post-receive hook which simply checks out the repository into /var/gemini which is mounted into the Molly Brown container that is running. In this way all the content just appears. The other piece is a Python script running out of cron that renders the contents of the Thoughts microblogging (ish) system I built on Azure Functions out to a text/gemini file.
https://www.going-flying.com/blog/thoughts-on-azure-functions.html
In the future I plan on building something resembling a blog here as well. I think the community is drifting towards ``glog'' but I suppose we'll see when it comes down to that. When I get to that point I imagine I'll end up building it similarly to my web blog, which is to say just create a directory full of text files with a metadata header and then generating the index page and the article pages from the git deploy script.
If any of this was interesting or you have any questions about this whole thing feel free to drop me a line at matt@going-flying.com
I launched the gemlog the day after I wrote this, and wrote a little bit about it in passing but nothing super specific. I eventually want to be able to provide access to the git repository behind this whole thing via gemini, but it is a bit tricky given that this is running in a container. Anyway, you may notice that the deploy hook now runs build.py. That walks the articles sub directory of whatever path it is given and renders out the proper index and item Gemini markup files as well as generating the atom feed of all of the posts. Like my web site it regenerates all content idempotently so it can be run over and over again on top of itself without worrying. Unlike my web site it is extremely simple, weighing in at around 200 lines (including comments and license information) versus the web version's 2000 lines. The difference is in no small thanks to how much simpler Gemini is to what even a fairly simple web site is expected to be these days.
kitsune@22:06:13 going-flying.com >wc -l build.py build/*.py build/mdx/*.py build/renderers/*.py 41 build.py 155 build/__init__.py 422 build/blog.py 67 build/buildconfig.py 51 build/mdx/__init__.py 88 build/mdx/canonicallinks.py 77 build/mdx/manpage.py 84 build/mdx/md_emoji.py 181 build/mdx/md_imgset.py 122 build/mdx/md_summarizer.py 291 build/mdx/md_video.py 241 build/mdx/md_waybackify.py 79 build/mdx/ogimage.py 11 build/renderers/__init__.py 87 build/renderers/blogindexpage.py 88 build/renderers/blogpostpage.py 161 build/renderers/page.py 61 build/renderers/sitemap.py 2307 total kitsune@22:07:27 going-flying.com >wc -l ../gemini/build/build.py 227 ../gemini/build/build.py
Built from 09c76dc8b9ebbfbe765106d5982eddcfccc731b7