Skip to content

Instantly share code, notes, and snippets.

@kantjer01
kantjer01 / upgraderr-move-export.sh
Created July 29, 2023 13:14
upgraderr-move-export.sh
#!/bin/bash
# This script moves torrents older than a set threshold to the export category.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
# set variables.
@kantjer01
kantjer01 / upgraderr-tag-export.sh
Created July 29, 2023 13:14
upgraderr-tag-export.sh
#!/bin/bash
# This script adds the 'export' tag to torrents older than a set threshold on the seedbox.
# cd /volume1/scripts/upgraderr
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
@kantjer01
kantjer01 / upgraderr-reannounce.sh
Created July 29, 2023 13:13
upgraderr-reannounce.sh
#!/bin/bash
# This script will reannounce the imported torrents on the localhost.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
log="$log_dir/reannounce.$(date +"%Y-%m-%d_%H.%M").log"
@kantjer01
kantjer01 / upgraderr-move_notImported.sh
Created July 29, 2023 13:12
upgraderr-move_notImported.sh
#!/bin/bash
# This script moves stuck imports to post-import category on both locahost and seedbox.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
log="$log_dir/move_notImported.$(date +"%Y-%m-%d_%H.%M").log"
@kantjer01
kantjer01 / upgraderr-move_noHL.sh
Created July 29, 2023 13:12
upgraderr-move_noHL.sh
#!/bin/bash
# This script moves torrents to the lts catgrory if they are no longer hardlinked, qbit tmm wil then move the files to an other volume for long term seeding.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
log="$log_dir/move_noHL.$(date +"%Y-%m-%d_%H.%M").log"
@kantjer01
kantjer01 / upgraderr-max_torrents.sh
Last active July 29, 2023 17:26
upgraderr-max_torrents.sh
#!/bin/bash
# This script removes the oldest movies and series torrents from qbit to keep the number of torrents per instance below a set number.
# Only a set maximum number a torrents will be deleted in each run.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
@kantjer01
kantjer01 / upgraderr-incomplete.sh
Last active August 5, 2023 14:48
upgraderr-incomplete.sh
#!/bin/bash
# This script removes torrents with missing files or torrents without any progress.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
log="$log_dir/incomplete.$(date +"%Y-%m-%d_%H.%M").log"
@kantjer01
kantjer01 / upgraderr-freespace.sh
Last active July 29, 2023 17:28
upgraderr-freespace.sh
#!/bin/bash
# This script deletes the oldest movies and series torrents on qbit instances on the localhost when the free disk space drops below a set value.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
log="$log_dir/freespace.$(date +"%Y-%m-%d_%H.%M").log"
@kantjer01
kantjer01 / upgraderr-deltags.sh
Created July 29, 2023 13:09
upgraderr-deltags.sh
#!/bin/bash
# This script removes the 'export' tags from the qbit instance on the seedbox, and the 'imported' tags on the qbit instances on the localhost.
# load variables
set -o allexport
source /volume1/scripts/upgraderr/upgraderr.env
set +o allexport
log="$log_dir/deltags.$(date +"%Y-%m-%d_%H.%M").log"
@kantjer01
kantjer01 / upgraderr.env
Last active July 29, 2023 13:08
upgraderr.env
# Set the webhook URL
webhook_url="http://127.0.0.1:6940/api/expression"
# # set local qbit login credentials
host_movies_local="http://192.168.1.250:8088"
host_series_local="http://192.168.1.250:8080"
user_local="REDACTED"
password_local="REDACTED"
# set remote qbit login credentials