wut-aria-* scripts for downloading Internet Archive torrents

master
Jeff Moe 2022-06-11 16:05:38 -06:00
parent 270178d027
commit b6ac03590a
3 changed files with 31 additions and 0 deletions

View File

@ -74,6 +74,8 @@ Jupyter notebooks into websites.
The following scripts are in the repo.
* `wut` --- Feed it an observation ID and it returns if it is a "good", "bad", or "failed" observation.
* `wut-aria-add` --- Add a torrent from the Internet Archive to the aria daemon for downloading.
* `wut-aria-daemon` --- Run an aria daemon for torrent downloads from the Internet Archive.
* `wut-audio-archive` --- Downloads audio files from archive.org.
* `wut-audio-sha1` --- Verifies sha1 checksums of files downloaded from archive.org.
* `wut-compare` --- Compare an observations' current presumably human vetting with a `wut` vetting.

6
wut-aria-add 100755
View File

@ -0,0 +1,6 @@
#!/usr/bin/env python3
import xmlrpc.client as xmlrpclib
s = xmlrpclib.ServerProxy('http://localhost:4800/rpc')
s.aria2.addTorrent("token:yajnuAdCemNathNojdi", xmlrpclib.Binary(open('/srv/dl/satnogs-observations-000100001-000110000/satnogs-observations-000100001-000110000_archive.torrent', mode='rb').read()))

23
wut-aria-daemon 100755
View File

@ -0,0 +1,23 @@
#!/bin/bash
set -x
mkdir -p ~/log /srv/dl
aria2c \
--daemon=true \
--enable-rpc=true \
--dir=/srv/dl \
--rpc-listen-port=4800 \
--rpc-listen-all=false \
--rpc-secret=`cat /home/jebba/.aria-secret` \
--deferred-input=true \
--disable-ipv6=true \
--disk-cache=128M \
--file-allocation=falloc \
--log-level=notice \
--log=/home/jebba/log/aria.log \
--bt-max-open-files=1000 \
--bt-max-peers=1000 \
--continue=true