-- Leo's gemini proxy

-- Connecting to moddedbear.xyz:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

Setting Up Gemfeed


I decided to try setting up an atom feed of my logs that people can subscribe to. Here's how I did it in case other folks are curious about setting one up themselves.


I turned to Solderpunk's gemfeed.py[2], which will find all .gmi or .gemini files in a given directory and generate an atom feed with them.


I cloned gemfeed's repo and tried running it but got a ValueError about the date from one of my posts not matching a specified format.


ValueError: time data '2020-02-06 Z' does not match format '%Y-%m-%d %z'

I was able to get around this by applying a small two line fix to gemfeed.py, which I've linked to below[3].


If you're getting an error other than the one above, I've heard from some people that they needed to install a few dependencies before gemfeed would work. If you think this applies to you then check out bbbhltz's guide where you can find a a list of the dependencies you'll likely need and how to install them.

gemini://gemini.bbbhltz.space/gemlog/2021-02-10-howto-agate-on-pi.gmi


After this, gemfeed.py was able to read all the logs on my capusle and generate a working feed from them. The last thing I did was set a cronjob that will run gemfeed.py every 30 minutes so that the feed is always reasonably up to date with new logs.


I'll refer you to gemfeed's readme instead of repeating a lot of the same information here, but for reference the command I use is

./gemfeed.py -b gemini://moddedbear.xyz/logs -d /home/moddedbear/gemini/logs

My crontab looks like

0,30 * * * * /home/moddedbear/gemfeed.py -q -b gemini://moddedbear.xyz/logs -d /home/moddedbear/gemini/logs

And I'm using python 3.6.9 on Ubuntu 18.04.


Links

Home

The gemfeed git repo

The fix for gemfeed.py I used

Tips for maintaining your gemini capsule

-- Response ended

-- Page fetched on Thu Mar 28 19:29:16 2024