mirror of
https://codeberg.org/hyperreal/admin-scripts
synced 2024-11-25 09:03:41 +01:00
Fix org-mode headings
This commit is contained in:
parent
20bd5043c5
commit
b01b077730
@ -2,7 +2,7 @@
|
||||
|
||||
These are scripts I use to automate various tasks in my homelab.
|
||||
|
||||
⊘ bin
|
||||
** 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.
|
||||
- ~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.
|
||||
@ -10,10 +10,10 @@ These are scripts I use to automate various tasks in my homelab.
|
||||
- ~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
|
||||
** 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
|
||||
*** 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.
|
||||
|
@ -41,7 +41,7 @@ if __name__ == "__main__":
|
||||
tracker_urls = [x for x in response.text.splitlines() if x != ""]
|
||||
combined_trackers_urls.extend(tracker_urls)
|
||||
|
||||
combined_trackers_urls = [f"{x}\n" for x in combined_trackers_urls]
|
||||
for torrent in qb.torrents():
|
||||
qb.add_trackers(torrent.get("hash"), combined_trackers_urls) # type: ignore
|
||||
print(f"Added trackers to {torrent.get("name")}") # type: ignore
|
||||
for tracker in combined_trackers_urls:
|
||||
qb.add_trackers(torrent.get("hash"), f"{tracker}\n") # type: ignore
|
||||
print(f"Added {tracker} to {torrent.get("name")}") # type: ignore
|
Loading…
Reference in New Issue
Block a user