Skip to main content

(Beautiful) replacement for the 'http.server' Python3 module. Allows file upload, preview and much more.

Project description

http.server

A (beautiful) replacement for the http.server Python3 module.

pip3 install beautify-http-server

Features:

  • File download 🤷‍♂️
  • File upload 🤩
  • Preview (pdf, text, image, music, video) 🧐
  • List files in .zip and .tar archives remotely, with the ability to view or download a single entry 😮
  • Mobile-friendly 🤳

Example

  • Preview:

  • Mobile:



Dev Tips: force to view a zip-like file by passing #zip in the URL 😉


Usage

After installation (pip3 install beautify-http-server, see below), run:

$ # to serve current working directory, on 127.0.0.1:8000
$ http.server

$ http.server --bind 0.0.0.0 --port 8080 --folder ~/Downloads

$ http.server -h
usage: http.server [-h] [--bind BIND] [--port PORT] [--folder FOLDER]
                   [--debug | --no-output]

optional arguments:
  -h, --help       show this help message and exit
  --bind BIND      Specify bind address [default: 127.0.0.1]
  --port PORT      Specify server port [default: 8000]
  --folder FOLDER  Specify which directory to serve [default: current working
                   directory]
  --debug          Use "flask.run" in Debug mode instead of "waitress" WSGI
                   server
  --no-output      Disable server output (set logging.level >= WARNING)

ATTENTION: this program is meant to be run locally, do not expose on Internet!


Installation

As easy as:

$ pip3 install beautify-http-server

Otherwise:

$ # (Optional)
$ virtualenv venv && source venv/bin/activate

$ git clone https://www.github.com/lorenzodifuccia/http.server
$ cd http.server
$ pip install .

$ python3 -m http_server ...
OR
$ http.server ...

This project has the following dependencies:


Future

Known issues:

  • HTML5 and Browsers do not fully support .mkv files

Made with <3 by me

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

beautify-http-server-0.0.1.tar.gz (13.9 kB view hashes)

Uploaded Source

Built Distribution

beautify_http_server-0.0.1-py3-none-any.whl (15.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page