Skip to content
This repository has been archived by the owner on Jan 30, 2022. It is now read-only.

Latest commit

 

History

History
92 lines (67 loc) · 4.04 KB

README.md

File metadata and controls

92 lines (67 loc) · 4.04 KB

Mini Remote Downloader Codacy Badge GPA codecov Build Status

A simple web app to help you download files on server, it's like a proxyed downloader, useful when certain sites are blocked or you just want download files at home or wherever you are. Built with as little dependecies as possible.

Optionally supports downloading video or audio from Youtube/Openload and sending notification via PushBullet. It is protected by Basic Auth and each user can be notified individually.

Installation

  1. Clone this repo

    git clone https://github.com/P1-Ro/mini-remote-downloader.git
    
  2. Install minimal requirements

     pip install -r requirements.txt
    
  3. Replace placeholders in config.yml

    path: PATH
    username: USERNAME
    password: PASSWORD
    
  4. Start python app

    python app.py
    

Usage

You can use downloader with included web interface or via POST request.

Web Interface

Navigate your browser to http://{SERVER_ADDRESS}:9000, browser will ask you for username and password. After login you can start downloading. Here is screenshot:

Screenshot of web interface

Request

To start downloading simply make POST request on http://{SERVER_ADDRESS}:9000/download/ with JSON body which looks like this:

{
    "url": "http://example.com",     // url to be downloaded
    "name": "example" [optional],    // new name of downloaded file
    "category": "example" [optional] // subfolder in downloads folder
    "audioOnly": true [optional]     // if you want to download only audio from Youtube
}

And also use Authorization header with same USERNAME and PASSWORD you set in config.yml , otherwise you will get 401 Unathorized response (Unless it is on local network with local_network_without_login set to True)

If dowloading started successfully Status code 200 will be returned, otherwise Status code will be 500 with actual error message in JSON.

Optional

Enable downloading from Youtube and Openload

If you want to be able download videos from youtube you need to perform these steps.

  1. Install youtube-dl
pip install youtube-dl
  1. [Optional] Install PhantomJs if you want to download from Openload:

    Installation for Linux

    Installation for Windows

  2. [Optional] Install FFmpeg if you want to download mp3 from Youtube

    Installation guide for Linux and Windows

Enable notifications via PushBullet

If you want also get notification on your mobile phone or PC after download is complete perform these steps.

  1. Install pushbullet.py
pip install pushbullet.py
  1. Set flag notify_via_pushbullet in config.yml to True
  2. Set pushbullet_token in config.yml to your Access Token, which you can get here
  3. Repeat steps 2 and 3 for every user you want to get notified.

TODOS

  • Add progress/download screen similar to what browser use
  • Make pages responsive
  • Make one click executable for Windows