Ubuntu Install Aria2c for Downloads with WebUI
This is a simple guide on how to install and configure Aria2c with WebUI for downloading files on your linux server.
For the WebUI, we'll go with lighttpd as it is lightweight, however you can install apache or nginx or even run the file directly from your computer.
Lets start by updating the server, then installing and enabling the lighttpd module as well as a few other modules.
1 2 3 4 5 | |
Now lets get the latest static build of Aria2 OpenSSL from the build site: https://github.com/q3aql/aria2-static-builds/releases
You can also get it from our mirror: aria2-1.35.0-linux-gnu-64bit-build1.tar.bz2
Now transfer it to your home directory. If you would rather download it directly to your directory, do this (with the link you want). Then extract and install it.
1 2 3 4 | |
Now create a Aria2 downloads directory and configuration file:
1 2 | |
1 2 3 4 5 6 7 8 9 10 11 | |
Here you can set the default downloads directory, authentication token, and various other values. Be sure to set "check-certficate" to false if you are using Letsencrypt as it does not recognize Letsencrypt as of now.
Finally create a startup script for aria:
1 2 3 | |
1 2 | |
Finally add it to cron so it starts on boot:
1 | |
And append:
1 | |
Now, lets get the WebUI setup. Download the WebUI from: https://github.com/ziahamza/webui-aria2/
You can also get it from our mirror: aria2c-webui.zip
Upload it to your /var/www/html folder:
1 2 3 4 | |
Edit the app.js and add your authentication token for easy access.
1 | |
Find the line 342, which should say something like "(c = p && p.auth && p.auth.token ? p.auth.token : null),":
1 2 3 4 5 6 7 8 9 10 11 12 | |
And replace it with your authentication key in double quotes:
1 2 3 4 5 6 7 8 9 10 11 12 | |
Now save and exit. Finally restart your server:
1 | |
That's it. Now you can access Aria2 and its WebUI from your server.