admin-scripts/README.org

20 lines
1.9 KiB
Org Mode
Raw Normal View History

2024-06-20 17:12:41 +02:00
#+title: homelab-scripts
2024-07-21 17:31:34 +02:00
These are scripts I use to automate various tasks in my homelab.
2024-07-28 04:23:03 +02:00
⊘ bin
- ~add_scihub_torrents~ : This script uses [[https://github.com/charmbracelet/gum][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.
2024-07-22 15:13:12 +02:00
- ~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.
2024-07-21 17:31:34 +02:00
- ~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.
2024-07-28 04:23:03 +02:00
- ~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.
2024-07-21 17:31:34 +02:00
2024-07-28 04:23:03 +02:00
⊘ systemd
⊖ system
- ~server0-backup.service~ : A systemd service unit that runs the ~server0_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.