Skip to content

Commit 15a92ac

Browse files
committed
add ytdl-sub
1 parent ff48c7c commit 15a92ac

File tree

2 files changed

+147
-0
lines changed

2 files changed

+147
-0
lines changed

hosts/prod/default.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
./nginx.nix
1414
./restic.nix
1515
./wireguard.nix
16+
./youtube-downloads.nix
1617
];
1718

1819
filesystems.defaultLayout = true;

hosts/prod/youtube-downloads.nix

Lines changed: 146 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,146 @@
1+
{
2+
services.sshfs.mounts."/mnt/youtube" = {
3+
host = "u381435.your-storagebox.de";
4+
port = 23;
5+
user = "u381435";
6+
path = "youtube";
7+
readOnly = false;
8+
allowOther = true;
9+
};
10+
11+
services.ytdl-sub.instances.default = {
12+
enable = true;
13+
schedule = "3/8:17";
14+
readWritePaths = [ "/mnt/youtube" ];
15+
16+
config = {
17+
presets."YouTube Playlist" =
18+
let
19+
base_name = "{subscription_name}/{playlist_index_padded}_{uid}_{%sanitize(title)}";
20+
in
21+
{
22+
preset = [
23+
"Best Video Quality"
24+
"Chunk Downloads"
25+
];
26+
download = "{subscription_value}";
27+
output_options = {
28+
output_directory = "/mnt/youtube";
29+
file_name = "${base_name}.{ext}";
30+
maintain_download_archive = true;
31+
};
32+
chapters = {
33+
embed_chapters = true;
34+
sponsorblock_categories = "all";
35+
remove_sponsorblock_categories = [
36+
"sponsor"
37+
"selfpromo"
38+
"interaction"
39+
];
40+
};
41+
embed_thumbnail = true;
42+
subtitles = {
43+
subtitles_name = "${base_name}.{lang}.{subtitles_ext}";
44+
subtitles_type = "vtt";
45+
embed_subtitles = true;
46+
allow_auto_generated_subtitles = true;
47+
languages = [
48+
"en"
49+
"de"
50+
];
51+
};
52+
ytdl_options = {
53+
cookiefile = "/var/lib/ytdl-sub/default/.cookies";
54+
};
55+
overrides = {
56+
chunk_max_downloads = 200;
57+
};
58+
};
59+
};
60+
61+
subscriptions."YouTube Playlist" = {
62+
algorithmen_und_datenstrukturen = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7q2hZHyLJS6IeHQIlyEgKqf";
63+
angular_5 = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pY65LXhI1_bIcOByRhP9Xb";
64+
anonymitaet_im_internet = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7on8Ckrk2wo4ySeenf3rgf0";
65+
assembler = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rhjy2t320NvKKGwP6Rxnpg";
66+
bash = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7r-Tw-cNntRgvwA7nXPAjP4";
67+
binaere_mathematik = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rsjQsc8hFAdR4BlO_MQib1";
68+
binary_exploitation_secure_coding = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qff-bnM05OqSI0fx4GknZ6";
69+
bitcoin_blockchain_kryptowaehrungen = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oiW2UVh1Go8JgllRbZRcPK";
70+
clean_code = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7ryyZikMDPxxyYxEKtKn0ji";
71+
cloud = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oxg9u5X2a-9X_jpN8iPOQy";
72+
cpp = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oG-kkn36ZnDpRq6iahUXZS";
73+
c_sharp = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rlNexPh8wjI2DyABX8It7U";
74+
css3_fuer_anfaenger = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qQz698kYRkkBXJDeXJY_I7";
75+
c = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7q4shI4L__SRpetWff9BjLZ";
76+
dart_flutter = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qokXX4II7FCZthJcrirT4o";
77+
data_mining = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qIOuGJrd-lu-ZZc9t4EdwM";
78+
datenvisualisierung = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pb4apqIMKvCz37t_dLznMm";
79+
devops_grundlagen = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pSbRnMtEG5XEdYVwJE5se9";
80+
docker = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oea6IDCLzpKe5XfLmWCwgr";
81+
firewalls = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oAAFVjNrAz1uRqIcanXreg";
82+
ghidra_reverse_engineering = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oQc3MxjWB-rYHHo9vX905a";
83+
git_und_github = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rbmmqb1Lt_RGU4DEhelTrR";
84+
graphentheorie = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7q2hZHyLJS6IeHQIlyEgKqf";
85+
haskell = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pFIXDN1NLw6jMExuK-wN8I";
86+
html5_fuer_anfaenger = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qIbKPeroqn3-BkUTWzYBT4";
87+
iam = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rBqyMDGlv4LZmNrq1gChjh";
88+
it_sicherheit_hacken_essentials = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oVGaVtkLlu3jYl_D8ugxeT";
89+
java_algorithmen = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7o4qcD8tepVY5k7YiHYfMu5";
90+
java_fortgeschrittene_techniken = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oirQMpjPjrmNx4vcVIGIGY";
91+
java_ray_tracing = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rvhHip_LTM-J-5wHw7dWnw";
92+
javascript_express = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7ogA_q-mOoYH3dDQIh8B3Oe";
93+
javascript_jest = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qgQ2jnCFTo_knQTbpU5W4X";
94+
javascript = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qOfMI2ZNk-LXUAiXKrwDIi";
95+
java_swing = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7o5ALam15-pQWtf22RgU6D7";
96+
java = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qI9vtiiU5bJBfbxqBailVM";
97+
jquery = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qbE13388pQpsXQkpRQ96sM";
98+
kotlin_fortgeschrittene_techniken = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rylgyThgUldHG8KE6Nbc1O";
99+
kotlin = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rylgyThgUldHG8KE6Nbc1O";
100+
kryptographie = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pWwFv5APk240hrehtCJae-";
101+
lambda_kalkuel = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oBz3PP5sGIkLnmBbw10UUP";
102+
latex = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7phxF5hBRWNJx9-KtIHjVYv";
103+
linux_autokey = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qCtvw6fiki0ihkwv7tIWN_";
104+
linux_distributionen = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7o15uBS2J9Ryz-pM-P9xcWJ";
105+
linux_gnupg = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pUKpzMbzggvudByxULkut-";
106+
linux = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oaopPUB0SEmzZLf3aE5msy";
107+
llms = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7r4pg1j8eFsEQp3nL0w4jJz";
108+
logik = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7r7ztDWJ66pMNRYaa_TUjKP";
109+
machine_learning = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qoIUw0MBYQ9qJffZAVdRWC";
110+
medienkompetenz = "https://www.youtube.com/playlist?list=PL6RbeNL8jYDees12cwPupr49wMArrVQEX";
111+
mengenlehre = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7q_xBcMAlQ2K18HjMpAe0Nm";
112+
netzsicherheit = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7ovwsL-PKfByCX-jGuZAopM";
113+
netzwerktechnik = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rjW6OL4aGL-L1SzBUijh8r";
114+
nodejs = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7o-5JThNbEVW6CGAhWJwnkA";
115+
php_fuer_anfaenger = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rZMP1lj32Qyp4bkarvzCGm";
116+
programmieren_lernen = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7onyAB57T0xqV2ZVSZOo79a";
117+
prolog = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7q7ODiEAnq2EnsP-8LMGtfw";
118+
python_data_science = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7o46LI06XkxAqcg4Ucm7pwn";
119+
python_flask = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7otfP2zTa8AIiNIWVg0BRqs";
120+
python_lets_code = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7p09TLbRQmqzbH81DHjBO8E";
121+
python_pillow = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7p6tJ5S5Yvbw3reoZcHdyfR";
122+
python_pyqt = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7ruNQIfS8NRpjzZIRq0A8QP";
123+
python_pytorch = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rx55Mai21reZtd_8m-qe27";
124+
python_selenium = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7ruEf-FwVD3Z5owHgdXNKlb";
125+
python_tensorflow = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oj8ijyHSTOoW9bHLlXQ7hp";
126+
python = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7q0ao69AIogD94oBgp3E9Zs";
127+
react_js = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oi_Q4whC28Yp12l1I-hauk";
128+
sass_scss = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oopYYGy5hX-Y6b07_3DPp5";
129+
serveradministration = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7orIal3z8bq8HlHxnN-CtXr";
130+
signalverarbeitung = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qvLZlbEiRwHoP0mbmAHNId";
131+
softskills = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rC5g_bZNxZF6lOjSfNBKkE";
132+
softwareengineering = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qNMn6zimfu4JPUklG-4Uu4";
133+
spark_pyspark = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pkk8-Yxa7mjAqi_E9DE_Z9";
134+
sql_und_datenbanken = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7qYPusTRflv3tkzhYoT-KiB";
135+
threejs = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rrmmZEVGA4GfLLNLlGipWo";
136+
typescript = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7pwHqtQSBXGBUNkyGGOJQXf";
137+
uml = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oC7U6tm0BOnGg1R9ont0Vo";
138+
unreal_engine = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7olLCliQ05e6hvEOl6sbBgv";
139+
windows10 = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7rRSgXNzZMV3XlrfklBugNW";
140+
wireshark = "https://www.youtube.com/playlist?list=PLNmsVeXQZj7oIlWv3K9xACZi3fHfYLKtj";
141+
142+
# TODO
143+
# lustige_web_ui_effekte = "";
144+
};
145+
};
146+
}

0 commit comments

Comments
 (0)