Skip to content

Instantly share code, notes, and snippets.

@GAS85
Last active July 8, 2024 00:16
Show Gist options
  • Select an option

  • Save GAS85/79849bfd09613067a2ac0c1a711120a6 to your computer and use it in GitHub Desktop.

Select an option

Save GAS85/79849bfd09613067a2ac0c1a711120a6 to your computer and use it in GitHub Desktop.

Revisions

  1. GAS85 revised this gist Mar 15, 2022. 1 changed file with 87 additions and 72 deletions.
    159 changes: 87 additions & 72 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -8,39 +8,44 @@ Your local IP network is 192.168.0.0/24
    ## 1. Installation
    Install aria2 package:

    ```
    ```bash
    sudo apt install aria2
    ```

    ## 2.Configuration

    a. create Token:

    ```
    ```bash
    openssl rand -base64 32
    ```

    b. Create and edit configuration file (I created it in user folder /home/user/.aria2/aria.conf file, at least few lines must be added:

    ```
    dir=/home/user/torrents #Or other directory to save downloads
    rpc-secret=YOUR TOKEN FROM ABOVE
    ```bash
    # Or other directory to save downloads
    dir=/home/user/torrents
    rpc-secret=YOUR_TOKEN_FROM_ABOVE
    enable-rpc=true
    rpc-listen-all=true
    daemon=true
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-secure=true #enable encryption
    # Your Certificate file
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx
    # Enable encryption
    rpc-secure=true
    ```
    Optional:
    ```
    ```bash
    # For Web UI
    rpc-listen-port=6800
    listen-port=6801 #for torrents
    dht-listen-port=6801 #for torrents
    # For torrents
    listen-port=6801
    dht-listen-port=6801
    ```

    c. Create PFX certificate. Please, leave "Password" field empty when it's prompted:

    ```
    ```bash
    cd /usr/local/etc/aria2
    sudo openssl req -x509 -nodes -days 3650 -newkey rsa:1024 -keyout aria2.pem -out aria2.pem
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    @@ -49,16 +54,16 @@ c. Create PFX certificate. Please, leave "Password" field empty when it's prompt

    ## My full configuration looks as following:

    ```
    ```bash
    dir=/home/user/torrent
    file-allocation=trunc
    continue=true
    daemon=true
    ##
    ## Logs
    log=/home/user/.aria2/aria2.log
    console-log-level=warn
    log-level=notice
    ##
    ## Some Limits
    max-concurrent-downloads=5
    max-connection-per-server=5
    min-split-size=20M
    @@ -68,15 +73,18 @@ disable-ipv6=true
    input-file=/home/user/.aria2/aria2.session
    save-session=/home/user/.aria2/aria2.session
    save-session-interval=30
    ##
    ## RPC
    enable-rpc=true
    rpc-allow-origin-all=true
    rpc-listen-all=true
    rpc-listen-port=6800 #Port for JSON RPC
    rpc-secret=YOUR TOKEN FROM ABOVE
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-secure=true #enable encryption
    ##
    # Port for JSON RPC
    rpc-listen-port=6800
    rpc-secret=YOUR_TOKEN_FROM_ABOVE
    # Your Certificate file
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx
    # Enable encryption
    rpc-secure=true
    ## Torrents Settings
    follow-torrent=mem
    follow-metalink=mem
    enable-dht6=false
    @@ -87,21 +95,24 @@ seed-time=0
    bt-seed-unverified=true
    bt-save-metadata=true
    bt-force-encryption=true
    listen-port=6801 #Torrent TCP port
    dht-listen-port=6801 #Torrent UDP port
    # Torrent TCP port
    listen-port=6801
    # Torrent UDP port
    dht-listen-port=6801
    ```

    If you whant to use it, please create file `/home/user/.aria2/aria2.session` with correct ownership otherwise Aria will not be able to start.

    d. If you have iptables add something like this:

    ```
    iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT
    ```
    ```bash
    iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT
    ```

    e. Start Aria2 and set configuration location:

    ```
    ```bash
    aria2c --conf-path="/home/user/.aria2/aria2.conf"
    ```

    @@ -115,15 +126,19 @@ and click _*"add this site to trusted, permanently"*_.
    ## 4. You can use Aria2 with Letsencrypt Certificate

    just make changes in config:
    ```
    # Comment out your PFX if you created it as written above
    #rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    rpc-secure=true
    ```
    Please be aware that user set in point 7 below (or user that running Aria2) should have an access to those files. You can check if user has an access via command

    ```bash
    # Comment out your PFX if you created it as written above
    # Your Certificate file
    #rpc-certificate=/usr/local/etc/aria2/aria2.pfx
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    rpc-secure=true
    ```

    Please be aware that user set in point 7 below (or user that running Aria2) should have an access to those files. You can check if user has an access via command

    ```bash
    sudo -u user ls -la /etc/letsencrypt/live/YourDomain/privkey.pem
    #OR
    sudo -u user test -r /etc/letsencrypt/live/YourDomain/privkey.pem && echo YES || echo NO
    @@ -143,31 +158,31 @@ sudo -u user test -r /etc/letsencrypt/live/YourDomain/privkey.pem && echo YES ||

    ## 2. Edit configuration:

    ```
    ```bash
    sudo nano /var/www/webui-aria2-master/configuration.js
    ```

    change following lines:

    ```
    host: location.protocol.startsWith('https') ? location.hostname : '192.168.0.111',
    path: '/jsonrpc',
    port: 6800,
    encrypt: true,
    auth: { // either add the token field or the user and pass field, not both.
    // token: '$YOUR TOKEN FROM ABOVE$'
    ```
    ```js
    host: location.protocol.startsWith('https') ? location.hostname : '192.168.0.111',
    path: '/jsonrpc',
    port: 6800,
    encrypt: true,
    auth: { // either add the token field or the user and pass field, not both.
    // token: '$YOUR_TOKEN_FROM_ABOVE$'
    ```
    ## 3. Create Apache2 configuration for webIU:
    ```
    cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf
    ```
    ```bash
    cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf
    ```
    with following text to enable you local LAN only:
    ```
    ```bash
    <IfModule alias_module>
    Alias /webui-aria2 /var/www/webui-aria2-master
    <Directory "/var/www/webui-aria2-master">
    @@ -182,17 +197,17 @@ with following text to enable you local LAN only:
    ## 4. Enable config:
    ```
    ```bash
    sudo ln -s 002-aria2.conf ../sites-enabled
    ```
    or
    ```
    ```bash
    sudo a2ensite 002-aria2.conf
    ```
    ## 5. Restart Apache2
    ```
    ```bash
    sudo service apache2 restart
    ```
    @@ -204,28 +219,28 @@ Read how to enable reverse aria2 Proxy here https://gist.github.com/GAS85/d5ff94

    ## 7 You can create a service to make it easier:

    ```
    ```bash
    sudo nano /lib/systemd/system/aria2.service
    ```

    with following text:

    ```
    [Unit]
    Description=Aria2c download manager
    Requires=network.target
    After=dhcpcd.service
    [Service]
    Type=forking
    User=user
    Group=samegroup
    ExecStart=/usr/bin/aria2c --conf-path=/home/user/.aria2/aria2.conf
    WorkingDirectory=/home/user/torrents
    ExecReload=/usr/bin/kill -HUP $MAINPID
    RestartSec=1min
    Restart=on-failure
    [Install]
    WantedBy=multi-user.target
    ```
    ```bash
    [Unit]
    Description=Aria2c download manager
    Requires=network.target
    After=dhcpcd.service
    [Service]
    Type=forking
    User=user
    Group=samegroup
    ExecStart=/usr/bin/aria2c --conf-path=/home/user/.aria2/aria2.conf
    WorkingDirectory=/home/user/torrents
    ExecReload=/usr/bin/kill -HUP $MAINPID
    RestartSec=1min
    Restart=on-failure
    [Install]
    WantedBy=multi-user.target
    ```
  2. GAS85 revised this gist May 20, 2020. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -90,7 +90,7 @@ bt-force-encryption=true
    listen-port=6801 #Torrent TCP port
    dht-listen-port=6801 #Torrent UDP port
    ```
    If you whant to use it, please create file /home/user/.aria2/aria2.session with correct ownership otherwise Aria will not be able to start.
    If you whant to use it, please create file `/home/user/.aria2/aria2.session` with correct ownership otherwise Aria will not be able to start.

    d. If you have iptables add something like this:

    @@ -125,6 +125,8 @@ just make changes in config:
    Please be aware that user set in point 7 below (or user that running Aria2) should have an access to those files. You can check if user has an access via command
    ```
    sudo -u user ls -la /etc/letsencrypt/live/YourDomain/privkey.pem
    #OR
    sudo -u user test -r /etc/letsencrypt/live/YourDomain/privkey.pem && echo YES || echo NO
    ```

    ----------
  3. GAS85 revised this gist Feb 12, 2020. 1 changed file with 28 additions and 8 deletions.
    36 changes: 28 additions & 8 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -8,13 +8,17 @@ Your local IP network is 192.168.0.0/24
    ## 1. Installation
    Install aria2 package:

    ```sudo apt install aria2```
    ```
    sudo apt install aria2
    ```

    ## 2.Configuration

    a. create Token:

    ```openssl rand -base64 32```
    ```
    openssl rand -base64 32
    ```

    b. Create and edit configuration file (I created it in user folder /home/user/.aria2/aria.conf file, at least few lines must be added:

    @@ -97,7 +101,9 @@ d. If you have iptables add something like this:

    e. Start Aria2 and set configuration location:

    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```
    ```
    aria2c --conf-path="/home/user/.aria2/aria2.conf"
    ```

    ## 3 Firefox denies to use self-signed certificate
    you have to *add* it to the trusted list. Point browser to https://YOUR_SERVER_IP:6800/jsonrpc, e.g.:
    @@ -110,6 +116,8 @@ and click _*"add this site to trusted, permanently"*_.

    just make changes in config:
    ```
    # Comment out your PFX if you created it as written above
    #rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    rpc-secure=true
    @@ -133,7 +141,9 @@ sudo -u user ls -la /etc/letsencrypt/live/YourDomain/privkey.pem

    ## 2. Edit configuration:

    ```sudo nano /var/www/webui-aria2-master/configuration.js```
    ```
    sudo nano /var/www/webui-aria2-master/configuration.js
    ```

    change following lines:

    @@ -170,21 +180,31 @@ with following text to enable you local LAN only:

    ## 4. Enable config:

    ```sudo ln -s 002-aria2.conf ../sites-enabled```
    ```
    sudo ln -s 002-aria2.conf ../sites-enabled
    ```
    or
    ```sudo a2ensite 002-aria2.conf```
    ```
    sudo a2ensite 002-aria2.conf
    ```

    ## 5. Restart Apache2

    ```sudo service apache2 restart```
    ```
    sudo service apache2 restart
    ```

    ## 6 Use it

    You can call your Aria WebUI under e.g. ```http(s)://192.168.0.111/webui-aria2```

    Read how to enable reverse aria2 Proxy here https://gist.github.com/GAS85/d5ff9443a3b2fdb39b7b67fac2f7eff4

    ## 7 You can create a service to make it easier:

    ```sudo nano /lib/systemd/system/aria2.service```
    ```
    sudo nano /lib/systemd/system/aria2.service
    ```

    with following text:

  4. GAS85 revised this gist Nov 7, 2019. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -112,6 +112,7 @@ just make changes in config:
    ```
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    rpc-secure=true
    ```
    Please be aware that user set in point 7 below (or user that running Aria2) should have an access to those files. You can check if user has an access via command
    ```
  5. GAS85 revised this gist Nov 7, 2019. 1 changed file with 13 additions and 13 deletions.
    26 changes: 13 additions & 13 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -106,6 +106,18 @@ you have to *add* it to the trusted list. Point browser to https://YOUR_SERVER_I

    and click _*"add this site to trusted, permanently"*_.

    ## 4. You can use Aria2 with Letsencrypt Certificate

    just make changes in config:
    ```
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    ```
    Please be aware that user set in point 7 below (or user that running Aria2) should have an access to those files. You can check if user has an access via command
    ```
    sudo -u user ls -la /etc/letsencrypt/live/YourDomain/privkey.pem
    ```

    ----------

    # Web UI
    @@ -193,16 +205,4 @@ with following text:
    [Install]
    WantedBy=multi-user.target
    ```

    ## 8. You can use Aria2 with Letsencrypt Certificate

    just added in config:
    ```
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    ```
    Please be aware that user set in point 7 should have an access to those files. You can check if user has an access via command
    ```
    sudo -u user ls -la /etc/letsencrypt/live/YourDomain/privkey.pem
    ```
    ```
  6. GAS85 revised this gist Nov 7, 2019. 1 changed file with 13 additions and 1 deletion.
    14 changes: 13 additions & 1 deletion aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -193,4 +193,16 @@ with following text:
    [Install]
    WantedBy=multi-user.target
    ```
    ```

    ## 8. You can use Aria2 with Letsencrypt Certificate

    just added in config:
    ```
    rpc-certificate=/etc/letsencrypt/live/YourDomain/fullchain.pem
    rpc-private-key=/etc/letsencrypt/live/YourDomain/privkey.pem
    ```
    Please be aware that user set in point 7 should have an access to those files. You can check if user has an access via command
    ```
    sudo -u user ls -la /etc/letsencrypt/live/YourDomain/privkey.pem
    ```
  7. GAS85 revised this gist Sep 13, 2019. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -86,6 +86,7 @@ bt-force-encryption=true
    listen-port=6801 #Torrent TCP port
    dht-listen-port=6801 #Torrent UDP port
    ```
    If you whant to use it, please create file /home/user/.aria2/aria2.session with correct ownership otherwise Aria will not be able to start.

    d. If you have iptables add something like this:

  8. GAS85 revised this gist Jun 14, 2019. 1 changed file with 4 additions and 2 deletions.
    6 changes: 4 additions & 2 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -164,9 +164,11 @@ with following text to enable you local LAN only:

    ```sudo service apache2 restart```

    ## 6 Use it under e.g. http(s)://192.168.0.111/webui-aria2
    ## 6 Use it

    ## 7 You can create a service to make it easear:
    You can call your Aria WebUI under e.g. ```http(s)://192.168.0.111/webui-aria2```

    ## 7 You can create a service to make it easier:

    ```sudo nano /lib/systemd/system/aria2.service```

  9. GAS85 revised this gist Apr 5, 2019. 1 changed file with 8 additions and 6 deletions.
    14 changes: 8 additions & 6 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    ```
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    OS: Ubuntu 18.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    IP Addr of your Aria2 server is 192.168.0.111
    Your local IP network is 192.168.0.0/24
    ```
    # Aria 2
    @@ -99,7 +99,7 @@ e. Start Aria2 and set configuration location:
    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```

    ## 3 Firefox denies to use self-signed certificate
    you have to *add* it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:
    you have to *add* it to the trusted list. Point browser to https://YOUR_SERVER_IP:6800/jsonrpc, e.g.:

    https://192.168.0.111:6800/jsonrpc

    @@ -124,7 +124,7 @@ and click _*"add this site to trusted, permanently"*_.
    change following lines:

    ```
    host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    host: location.protocol.startsWith('https') ? location.hostname : '192.168.0.111',
    path: '/jsonrpc',
    port: 6800,
    encrypt: true,
    @@ -156,8 +156,10 @@ with following text to enable you local LAN only:

    ## 4. Enable config:

    ```sudo ln 002-aria2.conf ../sites-enabled```

    ```sudo ln -s 002-aria2.conf ../sites-enabled```
    or
    ```sudo a2ensite 002-aria2.conf```

    ## 5. Restart Apache2

    ```sudo service apache2 restart```
  10. GAS85 revised this gist Apr 27, 2018. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -40,6 +40,7 @@ c. Create PFX certificate. Please, leave "Password" field empty when it's prompt
    cd /usr/local/etc/aria2
    sudo openssl req -x509 -nodes -days 3650 -newkey rsa:1024 -keyout aria2.pem -out aria2.pem
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    sudo chmod 604 aria2.pfx
    ```

    ## My full configuration looks as following:
  11. GAS85 revised this gist Apr 27, 2018. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -113,7 +113,7 @@ and click _*"add this site to trusted, permanently"*_.
    ```
    cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/
    unzip master.zip -d /var/www/
    ```

    ## 2. Edit configuration:
  12. GAS85 revised this gist Apr 20, 2018. 1 changed file with 11 additions and 11 deletions.
    22 changes: 11 additions & 11 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -4,13 +4,13 @@ Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24
    ```

    # 1. Installation
    # Aria 2
    ## 1. Installation
    Install aria2 package:

    ```sudo apt install aria2```

    # 2.Configuration
    ## 2.Configuration

    a. create Token:

    @@ -42,7 +42,7 @@ c. Create PFX certificate. Please, leave "Password" field empty when it's prompt
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    ```

    # My full configuration looks as following:
    ## My full configuration looks as following:

    ```
    dir=/home/user/torrent
    @@ -97,7 +97,7 @@ e. Start Aria2 and set configuration location:

    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```

    # 3 Firefox denies to use self-signed certificate
    ## 3 Firefox denies to use self-signed certificate
    you have to *add* it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:

    https://192.168.0.111:6800/jsonrpc
    @@ -108,7 +108,7 @@ and click _*"add this site to trusted, permanently"*_.

    # Web UI

    ### 1. Download it from Github:
    ## 1. Download it from Github:

    ```
    cd /tmp
    @@ -131,7 +131,7 @@ change following lines:
    // token: '$YOUR TOKEN FROM ABOVE$'
    ```

    # 3. Create Apache2 configuration for webIU:
    ## 3. Create Apache2 configuration for webIU:

    ```
    cd /etc/apache2/sites-available/
    @@ -153,17 +153,17 @@ with following text to enable you local LAN only:
    </IfModule>
    ```

    # 4. Enable config:
    ## 4. Enable config:

    ```sudo ln 002-aria2.conf ../sites-enabled```

    # 5. Restart Apache2
    ## 5. Restart Apache2

    ```sudo service apache2 restart```

    # 6 Use it under http(s)://192.168.0.111/webui-aria2
    ## 6 Use it under e.g. http(s)://192.168.0.111/webui-aria2

    # 7 You can create a service to make it easear:
    ## 7 You can create a service to make it easear:

    ```sudo nano /lib/systemd/system/aria2.service```

  13. GAS85 revised this gist Apr 20, 2018. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -106,17 +106,17 @@ and click _*"add this site to trusted, permanently"*_.

    ----------

    ### Web UI
    # Web UI

    # 1. Download it from Github:
    ### 1. Download it from Github:

    ```
    cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/
    ```

    # 2. Edit configuration:
    ## 2. Edit configuration:

    ```sudo nano /var/www/webui-aria2-master/configuration.js```

  14. GAS85 revised this gist Apr 20, 2018. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -104,6 +104,8 @@ you have to *add* it to the trusted list. Point browser to https://YOUR_SERVE_IP

    and click _*"add this site to trusted, permanently"*_.

    ----------

    ### Web UI

    # 1. Download it from Github:
  15. GAS85 revised this gist Apr 20, 2018. 1 changed file with 4 additions and 3 deletions.
    7 changes: 4 additions & 3 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -97,11 +97,12 @@ e. Start Aria2 and set configuration location:

    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```

    # 3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:
    # 3 Firefox denies to use self-signed certificate
    you have to *add* it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:

    https://111.222.111.222:6800/jsonrpc
    https://192.168.0.111:6800/jsonrpc

    and click *"add this site to trusted, permanently"*.
    and click _*"add this site to trusted, permanently"*_.

    ### Web UI

  16. GAS85 revised this gist Apr 20, 2018. 1 changed file with 11 additions and 11 deletions.
    22 changes: 11 additions & 11 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -42,7 +42,7 @@ c. Create PFX certificate. Please, leave "Password" field empty when it's prompt
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    ```

    #My full configuration looks as following:
    # My full configuration looks as following:

    ```
    dir=/home/user/torrent
    @@ -97,23 +97,23 @@ e. Start Aria2 and set configuration location:

    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```

    #3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:
    # 3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:

    https://111.222.111.222:6800/jsonrpc

    and click "add this site to trusted, permanently".
    and click *"add this site to trusted, permanently"*.

    ### Web UI

    #1. Download it from Github:
    # 1. Download it from Github:

    ```
    cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/
    ```

    #2. Edit configuration:
    # 2. Edit configuration:

    ```sudo nano /var/www/webui-aria2-master/configuration.js```

    @@ -128,14 +128,14 @@ change following lines:
    // token: '$YOUR TOKEN FROM ABOVE$'
    ```

    #3. Create Apache2 configuration for webIU:
    # 3. Create Apache2 configuration for webIU:

    ```
    cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf
    ```

    with following text to enable you local LAn only:
    with following text to enable you local LAN only:

    ```
    <IfModule alias_module>
    @@ -150,17 +150,17 @@ with following text to enable you local LAn only:
    </IfModule>
    ```

    #4. LN config:
    # 4. Enable config:

    ```sudo ln 002-aria2.conf ../sites-enabled```

    #5. Restart Apache2
    # 5. Restart Apache2

    ```sudo service apache2 restart```

    #6 Use it under http(s)://111.222.111.222/webui-aria2
    # 6 Use it under http(s)://192.168.0.111/webui-aria2

    #7 You can create a service to make it easear:
    # 7 You can create a service to make it easear:

    ```sudo nano /lib/systemd/system/aria2.service```

  17. GAS85 revised this gist Apr 18, 2018. 1 changed file with 4 additions and 3 deletions.
    7 changes: 4 additions & 3 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -88,7 +88,8 @@ dht-listen-port=6801 #Torrent UDP port

    d. If you have iptables add something like this:

    ```iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    ```
    iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT
    ```

    @@ -104,7 +105,7 @@ and click "add this site to trusted, permanently".

    ### Web UI

    #1. Download it fomr Github:
    #1. Download it from Github:

    ```
    cd /tmp
    @@ -134,7 +135,7 @@ change following lines:
    sudo nano 002-aria2.conf
    ```

    with following text:
    with following text to enable you local LAn only:

    ```
    <IfModule alias_module>
  18. GAS85 revised this gist Apr 4, 2018. 1 changed file with 16 additions and 8 deletions.
    24 changes: 16 additions & 8 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -18,7 +18,8 @@ a. create Token:

    b. Create and edit configuration file (I created it in user folder /home/user/.aria2/aria.conf file, at least few lines must be added:

    ```dir=/home/user/torrents #Or other directory to save downloads
    ```
    dir=/home/user/torrents #Or other directory to save downloads
    rpc-secret=YOUR TOKEN FROM ABOVE
    enable-rpc=true
    rpc-listen-all=true
    @@ -27,14 +28,16 @@ b. Create and edit configuration file (I created it in user folder /home/user/.a
    rpc-secure=true #enable encryption
    ```
    Optional:
    ```rpc-listen-port=6800
    ```
    rpc-listen-port=6800
    listen-port=6801 #for torrents
    dht-listen-port=6801 #for torrents
    ```

    c. Create PFX certificate. Please, leave "Password" field empty when it's prompted:

    ```cd /usr/local/etc/aria2
    ```
    cd /usr/local/etc/aria2
    sudo openssl req -x509 -nodes -days 3650 -newkey rsa:1024 -keyout aria2.pem -out aria2.pem
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    ```
    @@ -103,7 +106,8 @@ and click "add this site to trusted, permanently".

    #1. Download it fomr Github:

    ```cd /tmp
    ```
    cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/
    ```
    @@ -114,7 +118,8 @@ and click "add this site to trusted, permanently".

    change following lines:

    ```host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    ```
    host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    path: '/jsonrpc',
    port: 6800,
    encrypt: true,
    @@ -124,13 +129,15 @@ change following lines:

    #3. Create Apache2 configuration for webIU:

    ```cd /etc/apache2/sites-available/
    ```
    cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf
    ```

    with following text:

    ```<IfModule alias_module>
    ```
    <IfModule alias_module>
    Alias /webui-aria2 /var/www/webui-aria2-master
    <Directory "/var/www/webui-aria2-master">
    AllowOverride None
    @@ -158,7 +165,8 @@ with following text:

    with following text:

    ```[Unit]
    ```
    [Unit]
    Description=Aria2c download manager
    Requires=network.target
    After=dhcpcd.service
  19. GAS85 revised this gist Apr 4, 2018. 1 changed file with 5 additions and 10 deletions.
    15 changes: 5 additions & 10 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -91,8 +91,7 @@ d. If you have iptables add something like this:

    e. Start Aria2 and set configuration location:

    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"
    ```
    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```

    #3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:

    @@ -111,8 +110,7 @@ and click "add this site to trusted, permanently".

    #2. Edit configuration:

    ```sudo nano /var/www/webui-aria2-master/configuration.js
    ```
    ```sudo nano /var/www/webui-aria2-master/configuration.js```

    change following lines:

    @@ -146,20 +144,17 @@ with following text:

    #4. LN config:

    ```sudo ln 002-aria2.conf ../sites-enabled/
    ```
    ```sudo ln 002-aria2.conf ../sites-enabled```

    #5. Restart Apache2

    ```sudo service apache2 restart
    ```
    ```sudo service apache2 restart```

    #6 Use it under http(s)://111.222.111.222/webui-aria2

    #7 You can create a service to make it easear:

    ```sudo nano /lib/systemd/system/aria2.service
    ```
    ```sudo nano /lib/systemd/system/aria2.service```

    with following text:

  20. GAS85 revised this gist Apr 4, 2018. 1 changed file with 28 additions and 14 deletions.
    42 changes: 28 additions & 14 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -24,17 +24,20 @@ b. Create and edit configuration file (I created it in user folder /home/user/.a
    rpc-listen-all=true
    daemon=true
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-secure=true #enable encryption```
    rpc-secure=true #enable encryption
    ```
    Optional:
    ```rpc-listen-port=6800
    listen-port=6801 #for torrents
    dht-listen-port=6801 #for torrents```
    dht-listen-port=6801 #for torrents
    ```

    c. Create PFX certificate. Please, leave "Password" field empty when it's prompted:

    ```cd /usr/local/etc/aria2
    sudo openssl req -x509 -nodes -days 3650 -newkey rsa:1024 -keyout aria2.pem -out aria2.pem
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"```
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    ```

    #My full configuration looks as following:

    @@ -83,11 +86,13 @@ dht-listen-port=6801 #Torrent UDP port
    d. If you have iptables add something like this:

    ```iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT```
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT
    ```

    e. Start Aria2 and set configuration location:

    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```
    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"
    ```

    #3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:

    @@ -101,11 +106,13 @@ and click "add this site to trusted, permanently".

    ```cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/```
    unzip master.zip /var/www/
    ```

    #2. Edit configuration:

    ```sudo nano /var/www/webui-aria2-master/configuration.js```
    ```sudo nano /var/www/webui-aria2-master/configuration.js
    ```

    change following lines:

    @@ -114,12 +121,14 @@ change following lines:
    port: 6800,
    encrypt: true,
    auth: { // either add the token field or the user and pass field, not both.
    // token: '$YOUR TOKEN FROM ABOVE$'```
    // token: '$YOUR TOKEN FROM ABOVE$'
    ```

    #3. Create Apache2 configuration for webIU:

    ```cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf ```
    sudo nano 002-aria2.conf
    ```

    with following text:

    @@ -132,21 +141,25 @@ with following text:
    Allow from 192.168.0.0/24 localhost 127.0.0.1
    Deny from all
    </Directory>
    </IfModule>```
    </IfModule>
    ```

    #4. LN config:

    ```sudo ln 002-aria2.conf ../sites-enabled/```
    ```sudo ln 002-aria2.conf ../sites-enabled/
    ```

    #5. Restart Apache2

    ```sudo service apache2 restart```
    ```sudo service apache2 restart
    ```

    #6 Use it under http(s)://111.222.111.222/webui-aria2

    #7 You can create a service to make it easear:

    ```sudo nano /lib/systemd/system/aria2.service```
    ```sudo nano /lib/systemd/system/aria2.service
    ```

    with following text:

    @@ -166,4 +179,5 @@ with following text:
    Restart=on-failure
    [Install]
    WantedBy=multi-user.target```
    WantedBy=multi-user.target
    ```
  21. GAS85 revised this gist Apr 4, 2018. 1 changed file with 4 additions and 2 deletions.
    6 changes: 4 additions & 2 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,9 @@
    ```OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    ```
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24```
    Your local IP network is 192.168.0.0/24
    ```

    # 1. Installation
    Install aria2 package:
  22. GAS85 revised this gist Apr 4, 2018. 1 changed file with 27 additions and 27 deletions.
    54 changes: 27 additions & 27 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,38 +1,38 @@
    `OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    ```OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24`
    Your local IP network is 192.168.0.0/24```
    # 1. Installation
    Install aria2 package:
    ``sudo apt install aria2``
    ```sudo apt install aria2```
    # 2.Configuration
    a. create Token:
    ``openssl rand -base64 32``
    ```openssl rand -base64 32```
    b. Create and edit configuration file (I created it in user folder /home/user/.aria2/aria.conf file, at least few lines must be added:
    ``dir=/home/user/torrents #Or other directory to save downloads
    ```dir=/home/user/torrents #Or other directory to save downloads
    rpc-secret=YOUR TOKEN FROM ABOVE
    enable-rpc=true
    rpc-listen-all=true
    daemon=true
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-secure=true #enable encryption``
    rpc-secure=true #enable encryption```
    Optional:
    ``rpc-listen-port=6800
    ```rpc-listen-port=6800
    listen-port=6801 #for torrents
    dht-listen-port=6801 #for torrents``
    dht-listen-port=6801 #for torrents```
    c. Create PFX certificate. Please, leave "Password" field empty when it's prompted:
    ``cd /usr/local/etc/aria2
    ```cd /usr/local/etc/aria2
    sudo openssl req -x509 -nodes -days 3650 -newkey rsa:1024 -keyout aria2.pem -out aria2.pem
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"``
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"```
    #My full configuration looks as following:
    @@ -80,12 +80,12 @@ dht-listen-port=6801 #Torrent UDP port
    d. If you have iptables add something like this:
    ``iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT``
    ```iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT```
    e. Start Aria2 and set configuration location:
    ``aria2c --conf-path="/home/user/.aria2/aria2.conf"``
    ```aria2c --conf-path="/home/user/.aria2/aria2.conf"```
    #3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:
    @@ -97,31 +97,31 @@ and click "add this site to trusted, permanently".
    #1. Download it fomr Github:
    ``cd /tmp
    ```cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/``
    unzip master.zip /var/www/```
    #2. Edit configuration:
    ``sudo nano /var/www/webui-aria2-master/configuration.js``
    ```sudo nano /var/www/webui-aria2-master/configuration.js```
    change following lines:
    ``host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    ```host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    path: '/jsonrpc',
    port: 6800,
    encrypt: true,
    auth: { // either add the token field or the user and pass field, not both.
    // token: '$YOUR TOKEN FROM ABOVE$'``
    // token: '$YOUR TOKEN FROM ABOVE$'```
    #3. Create Apache2 configuration for webIU:
    ``cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf ``
    ```cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf ```
    with following text:
    ``<IfModule alias_module>
    ```<IfModule alias_module>
    Alias /webui-aria2 /var/www/webui-aria2-master
    <Directory "/var/www/webui-aria2-master">
    AllowOverride None
    @@ -130,25 +130,25 @@ with following text:
    Allow from 192.168.0.0/24 localhost 127.0.0.1
    Deny from all
    </Directory>
    </IfModule>``
    </IfModule>```
    #4. LN config:
    ``sudo ln 002-aria2.conf ../sites-enabled/``
    ```sudo ln 002-aria2.conf ../sites-enabled/```
    #5. Restart Apache2
    ``sudo service apache2 restart``
    ```sudo service apache2 restart```
    #6 Use it under http(s)://111.222.111.222/webui-aria2
    #7 You can create a service to make it easear:
    ``sudo nano /lib/systemd/system/aria2.service``
    ```sudo nano /lib/systemd/system/aria2.service```
    with following text:
    ``[Unit]
    ```[Unit]
    Description=Aria2c download manager
    Requires=network.target
    After=dhcpcd.service
    @@ -164,4 +164,4 @@ with following text:
    Restart=on-failure
    [Install]
    WantedBy=multi-user.target``
    WantedBy=multi-user.target```
  23. GAS85 revised this gist Apr 4, 2018. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    `OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24
    Your local IP network is 192.168.0.0/24`

    # 1. Installation
    Install aria2 package:
  24. GAS85 revised this gist Apr 4, 2018. 1 changed file with 8 additions and 6 deletions.
    14 changes: 8 additions & 6 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24

    # 1. Installation
    Install aria2 package:
    @@ -36,7 +36,8 @@ c. Create PFX certificate. Please, leave "Password" field empty when it's prompt

    #My full configuration looks as following:

    ``dir=/home/user/torrent
    ```
    dir=/home/user/torrent
    file-allocation=trunc
    continue=true
    daemon=true
    @@ -74,7 +75,8 @@ bt-seed-unverified=true
    bt-save-metadata=true
    bt-force-encryption=true
    listen-port=6801 #Torrent TCP port
    dht-listen-port=6801 #Torrent UDP port``
    dht-listen-port=6801 #Torrent UDP port
    ```

    d. If you have iptables add something like this:

  25. GAS85 revised this gist Apr 4, 2018. 1 changed file with 31 additions and 31 deletions.
    62 changes: 31 additions & 31 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    # OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    # Aim: to install Aria2 with WebUI and secure Token.
    # IP Addr of your Aria2 server is 111.222.111.222
    # Your local IP network is 192.168.0.0/24
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24

    # 1. Installation
    Install aria2 package:
    @@ -12,31 +12,31 @@ Install aria2 package:

    a. create Token:

    openssl rand -base64 32
    ``openssl rand -base64 32``

    b. Create and edit configuration file (I created it in user folder /home/user/.aria2/aria.conf file, at least few lines must be added:

    dir=/home/user/torrents #Or other directory to save downloads
    ``dir=/home/user/torrents #Or other directory to save downloads
    rpc-secret=YOUR TOKEN FROM ABOVE
    enable-rpc=true
    rpc-listen-all=true
    daemon=true
    rpc-certificate=/usr/local/etc/aria2/aria2.pfx #your Certificate file
    rpc-secure=true #enable encryption
    # Optional:
    rpc-listen-port=6800
    rpc-secure=true #enable encryption``
    Optional:
    ``rpc-listen-port=6800
    listen-port=6801 #for torrents
    dht-listen-port=6801 #for torrents
    dht-listen-port=6801 #for torrents``

    c. Create PFX certificate. Please, leave "Password" field empty when it's prompted:

    cd /usr/local/etc/aria2
    ``cd /usr/local/etc/aria2
    sudo openssl req -x509 -nodes -days 3650 -newkey rsa:1024 -keyout aria2.pem -out aria2.pem
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"
    sudo openssl pkcs12 -export -out aria2.pfx -in aria2.pem -name "Aria2 Certificate"``

    #My full configuration looks as following:

    dir=/home/user/torrent
    ``dir=/home/user/torrent
    file-allocation=trunc
    continue=true
    daemon=true
    @@ -74,16 +74,16 @@ bt-seed-unverified=true
    bt-save-metadata=true
    bt-force-encryption=true
    listen-port=6801 #Torrent TCP port
    dht-listen-port=6801 #Torrent UDP port
    dht-listen-port=6801 #Torrent UDP port``

    d. If you have iptables add something like this:

    iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT
    ``iptables -I INPUT -p tcp -m tcp --dport 6800:6801 -j ACCEPT
    iptables -I INPUT -p udp -m udp --dport 6801 -j ACCEPT``

    e. Start Aria2 and set configuration location:

    aria2c --conf-path="/home/user/.aria2/aria2.conf"
    ``aria2c --conf-path="/home/user/.aria2/aria2.conf"``

    #3 Firefox denies to use self-signed certificate, you have to add it to the trusted list. Point browser to https://YOUR_SERVE_IP:6800/jsonrpc, e.g.:

    @@ -95,31 +95,31 @@ and click "add this site to trusted, permanently".

    #1. Download it fomr Github:

    cd /tmp
    ``cd /tmp
    wget https://github.com/ziahamza/webui-aria2/archive/master.zip
    unzip master.zip /var/www/
    unzip master.zip /var/www/``

    #2. Edit configuration:

    sudo nano /var/www/webui-aria2-master/configuration.js
    ``sudo nano /var/www/webui-aria2-master/configuration.js``

    change following lines:

    host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    ``host: location.protocol.startsWith('https') ? location.hostname : '111.222.111.222',
    path: '/jsonrpc',
    port: 6800,
    encrypt: true,
    auth: { // either add the token field or the user and pass field, not both.
    // token: '$YOUR TOKEN FROM ABOVE$'
    // token: '$YOUR TOKEN FROM ABOVE$'``

    #3. Create Apache2 configuration for webIU:

    cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf
    ``cd /etc/apache2/sites-available/
    sudo nano 002-aria2.conf ``

    with following text:

    <IfModule alias_module>
    ``<IfModule alias_module>
    Alias /webui-aria2 /var/www/webui-aria2-master
    <Directory "/var/www/webui-aria2-master">
    AllowOverride None
    @@ -128,25 +128,25 @@ with following text:
    Allow from 192.168.0.0/24 localhost 127.0.0.1
    Deny from all
    </Directory>
    </IfModule>
    </IfModule>``

    #4. LN config:

    sudo ln 002-aria2.conf ../sites-enabled/
    ``sudo ln 002-aria2.conf ../sites-enabled/``

    #5. Restart Apache2

    sudo service apache2 restart
    ``sudo service apache2 restart``

    #6 Use it under http(s)://111.222.111.222/webui-aria2

    #7 You can create a service to make it easear:

    sudo nano /lib/systemd/system/aria2.service
    ``sudo nano /lib/systemd/system/aria2.service``

    with following text:

    [Unit]
    ``[Unit]
    Description=Aria2c download manager
    Requires=network.target
    After=dhcpcd.service
    @@ -162,4 +162,4 @@ with following text:
    Restart=on-failure

    [Install]
    WantedBy=multi-user.target
    WantedBy=multi-user.target``
  26. GAS85 revised this gist Apr 4, 2018. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -6,7 +6,7 @@
    # 1. Installation
    Install aria2 package:

    ´´´sudo apt install aria2'´´´
    ``sudo apt install aria2``

    # 2.Configuration

  27. GAS85 revised this gist Apr 4, 2018. 1 changed file with 5 additions and 5 deletions.
    10 changes: 5 additions & 5 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,12 +1,12 @@
    ## OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    ## Aim: to install Aria2 with WebUI and secure Token.
    ## IP Addr of your Aria2 server is 111.222.111.222
    ## Your local IP network is 192.168.0.0/24
    # OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    # Aim: to install Aria2 with WebUI and secure Token.
    # IP Addr of your Aria2 server is 111.222.111.222
    # Your local IP network is 192.168.0.0/24

    # 1. Installation
    Install aria2 package:

    'sudo apt install aria2'
    ´´´sudo apt install aria2'´´´

    # 2.Configuration

  28. GAS85 revised this gist Apr 4, 2018. 1 changed file with 7 additions and 7 deletions.
    14 changes: 7 additions & 7 deletions aria2c_webUI.md
    Original file line number Diff line number Diff line change
    @@ -1,14 +1,14 @@
    OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    Aim: to install Aria2 with WebUI and secure Token.
    IP Addr of your Aria2 server is 111.222.111.222
    Your local IP network is 192.168.0.0/24
    ## OS: Ubuntu 16.04 Apache/2.4.18 1.0.2g-1ubuntu4.10
    ## Aim: to install Aria2 with WebUI and secure Token.
    ## IP Addr of your Aria2 server is 111.222.111.222
    ## Your local IP network is 192.168.0.0/24

    #1. Installation
    # 1. Installation
    Install aria2 package:

    sudo apt install aria2
    'sudo apt install aria2'

    #2.Configuration
    # 2.Configuration

    a. create Token:

  29. GAS85 renamed this gist Apr 4, 2018. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  30. GAS85 revised this gist Apr 4, 2018. 1 changed file with 25 additions and 1 deletion.
    26 changes: 25 additions & 1 deletion aria2c_webUI.txt
    Original file line number Diff line number Diff line change
    @@ -138,4 +138,28 @@ with following text:

    sudo service apache2 restart

    #6 Use it under http(s)://111.222.111.222/webui-aria2
    #6 Use it under http(s)://111.222.111.222/webui-aria2

    #7 You can create a service to make it easear:

    sudo nano /lib/systemd/system/aria2.service

    with following text:

    [Unit]
    Description=Aria2c download manager
    Requires=network.target
    After=dhcpcd.service

    [Service]
    Type=forking
    User=user
    Group=samegroup
    ExecStart=/usr/bin/aria2c --conf-path=/home/user/.aria2/aria2.conf
    WorkingDirectory=/home/user/torrents
    ExecReload=/usr/bin/kill -HUP $MAINPID
    RestartSec=1min
    Restart=on-failure

    [Install]
    WantedBy=multi-user.target