Fixed Aria2 Errors, Automatically kill it, make it work with VPNs

This commit is contained in:
Vxrtrauter
2025-09-12 00:54:00 +02:00
parent 71ab31b537
commit 1c28d8e232
3 changed files with 42 additions and 5 deletions
+15 -3
View File
@@ -12,10 +12,22 @@ def run_aria2p():
secret=""
)
)
return aria2
def aria2server():
downloads_dir = os.path.join(os.path.expanduser("~"), "Downloads")
subprocess.Popen(["aria2c", "--enable-rpc", "--rpc-listen-all=true", f"--dir={downloads_dir}"])
cmd = [
"aria2c",
"--enable-rpc",
"--disable-ipv6", # added this since it caused problems with vpns
"--rpc-listen-all",
"--rpc-listen-port=6800",
f"--dir={downloads_dir}"
]
return aria2
aria2server = subprocess.Popen(cmd)
return aria2server