Skip to main content

a basic http 1.0 server implemented in python

Project description

companion

an http 1.0 web server, implemented with python

Note: This is not intended to be used in any form of a production environment. For sake of time, I didn't pay attention to every edge case or security concern.

Installation

First, install the companion server to your computer,

pip install companion-server

Now, we can run the server... The only required argument is a path to your content directory, this is how the server knows where to look for content (e.g. HTML, PNG, etc)

You can optionally specify a port otherwise it will default to 8180

companion-server /home/dan/webserver/content/ --port 1000

Goals

[x] Implement a subset of the http 1.0 protocol (rfc 1945)

[x] Handle GET and HEAD requests from a client

[x] Manage multiple connections (threading, multiprocessing, etc)

[x] Use only the python standard lib

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

companion_server-1.3.1.tar.gz (5.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

companion_server-1.3.1-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file companion_server-1.3.1.tar.gz.

File metadata

  • Download URL: companion_server-1.3.1.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.11.11 Linux/6.8.0-1021-azure

File hashes

Hashes for companion_server-1.3.1.tar.gz
Algorithm Hash digest
SHA256 3e765340a11c1f321b4ba18abc44e26dfda344dc94e6debed293fff794caa66f
MD5 522d061d1dde8d31865ca6a79913130a
BLAKE2b-256 d535e584361b2ac84ff94fc2f2b1bc016f1168f98f5dc28960bb59329cf1df64

See more details on using hashes here.

File details

Details for the file companion_server-1.3.1-py3-none-any.whl.

File metadata

  • Download URL: companion_server-1.3.1-py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.11.11 Linux/6.8.0-1021-azure

File hashes

Hashes for companion_server-1.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c51abeccd6d1d02a1897fcb5dda079a6bf45030f29047a83b3c7c33786367d0f
MD5 2953346a6e65614d06b101006a5b2cae
BLAKE2b-256 aa69c5d5e926acc6c2dde229580e265271f066452f8ae069cfc830b5a564836c

See more details on using hashes here.

Supported by

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