Skip to content

lovett/medley

Folders and files

NameName
Last commit message
Last commit date

Latest commit

dc3f956 · Feb 14, 2025
May 14, 2024
Feb 14, 2025
Mar 31, 2024
Nov 18, 2024
Sep 3, 2023
Feb 3, 2025
Mar 31, 2024
Feb 3, 2025
Feb 16, 2022
Mar 30, 2023
Jan 20, 2024
May 12, 2020
Feb 11, 2024
Oct 9, 2024
Jan 26, 2024
Aug 20, 2022
Sep 11, 2024
Sep 28, 2023
Oct 9, 2024
Feb 3, 2025
Aug 12, 2023
Oct 5, 2024
Oct 5, 2024
Apr 8, 2023
Dec 6, 2024
Dec 6, 2024
Oct 5, 2024

Repository files navigation

Medley

A collection of small web applications.

Development Setup

Medley is written in Python and targets version 3.11. Setup is driven by make.

# Create a virtual environment
make venv

# Install third-party libraries
make setup

# Start the server on localhost:8085
make serve

SELinux Configuration

sudo semanage port -a -t http_port_t -p tcp 8085
setsebool -P httpd_can_network_relay 1

Application Configuration

Medley's default configuration can be adjusted through environment variables.

MEDLEY_access_log: The file path for site-wide request logging. Default: Not set

MEDLEY_daemonize: Whether the server should run as a daemon. Unnecessary when the server is being manged by systemd and useful during development. Default: False

MEDLEY_database_dir: The directory path for SQLite databases. Default: ./db

MEDLEY_error_log: The file path for site-wide error logging. Unnecessary when the server is being managed by systemd (use journalctl instead). Default: Not set

MEDLEY_etags: Whether to use ETag HTTP headers for caching. Default: True

MEDLEY_gzip: Whether to enable gzip compression. Default: True

MEDLEY_log_headers: Whether error logging should include HTTP request headers. Default: False

MEDLEY_log_screen: Whether log messages should be written to the server's stdout. Default: True

MEDLEY_log_screen_access: Whether access logs should be written to the stdout of the server process. Only applicable if MEDLEY_log_screen is enabled. Default: False

MEDLEY_memorize_hashes: Whether the server should keep static asset file hashes in memory for use with HTTP cache control. Useful in production but not in development. Default: True

MEDLEY_notify_systemd: Whether the server should let systemd know it has started and is ready to receive requests. Default: False

MEDLEY_prefetch: Whether the server is allowed to poll certain external URLs on a recurring basis so that they can be served more quickly from cache when needed. Default: True

MEDLEY_server_host: The IP the server should listen on. Default: 127.0.0.1

MEDLEY_server_port: The port the server should listen on. Default: 8085

MEDLEY_tracebacks: Whether CherryPy should display Python error trackebacks in the browser. Default: False

Acknowledgements

This project gratefully makes use of the following projects:

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published