mirror of
https://codeberg.org/hyperreal/admin-scripts
synced 2024-11-01 16:03:06 +01:00
bin | ||
systemd | ||
justfile | ||
LICENSE | ||
README.org |
homelab-scripts
These are scripts I use to automate various tasks in my homelab.
bin
add_scihub_torrents
: This script uses gum to select paginated text files that contain URLs of Sci Hub torrent files. For each selected file, the URLs are read and added to a qBittorrent instance.
qbth
: This is a helper program for adding Linux and BSD distros to a qBittorrent instance. It's a bit crude, and the Python linter yells at me for it, but it gets the job done, and that's all I need it to do. Thank you.qbt_sum_size
: This script prints the total size of completed torrents and the total size of all torrents added to a qBittorrent instance. The former is a subset of the latter.seed_armbian_torrents
: This script downloads an archive from Armbian, extracts the torrent files within to a temporary directory, and adds each file to a qBittorrent instance. It first removes older Armbian torrents from the qBittorrent instance.seed_scihub_torrents
: This script finds which torrents have less than or equal to N seeders, where N is an integer argument supplied by the user. It then adds these torrents to a qBittorrent instance.server0_backup
: This script dumps my Mastodon instance's PostgreSQL database, then uses rclone to sync/etc
,/var/log
, and/home/jas
to an S3-compatible object storage bucket (MinIO). It also copies the dumped Mastodon database and.env.production
to the object storage bucket.
systemd
system
server0-backup.service
: A systemd service unit that runs theserver0_backup
script.server0-backup.timer
: A systemd timer unit that triggers the corresponding service unit.
user
glances.service
: A systemd service unit for the user scope that runs a glances server.gmcapsuled.service
: A systemd service unit for the user scope that runs the gmcapsuled Gemini server.