Open
Description
I don't know how to submit a PR, so here are my files for your use for now.
# /etc/systemd/system/fedifetcher.service
[Unit]
Description=FediFetcher Service
After=network.target mastodon-web.service mastodon-sidekiq.service mastodon-streaming@<REPLACE_WITH_YOUR_PORT_NUMBER>.service
[Service]
Type=simple
User=mastodon
# WorkingDirectory is your checked-out FediFetcher repo directory
# I don't like having only case-seperate same paths, so this is mine
WorkingDirectory=/opt/fedifetcher/venv/FediFetcher
# ExecStart must use the python binary created in the venv
ExecStart=/opt/fedifetcher/venv/bin/python3 find_posts.py -c=artifacts/config.json
# /etc/systemd/system/fedifetcher.timer
[Unit]
Description=FediFetcher Timer
[Timer]
# don't start until system has settled (adjust as you need)
OnBootSec=15min
# after the unit has run once, wait a minute, then run again (removes dependency on lockfile, I think)
OnUnitActiveSec=1min
[Install]
WantedBy=timers.target