Package: netix
Netix ASGI ServerNetix is a high-performance ASGI (Asynchronous Server Gateway Interface) server designed for efficiently serving ASGI web applications and APIs. It offers a robust, customizable, and easy-to-use platform for deploying your ASGI applications.Table of ContentsFeaturesInstallationGetting StartedConfigurationAvailable Commands and OptionsMiddleware SupportContributingLicenseAcknowledgmentsSupport and FeedbackFeaturesConcurrency Control: Easily set the number of worker processes to manage concurrent requests efficiently.Socket Options: Support for both Unix sockets and network sockets with customizable socket options.Middleware Support: Implement request and response middlewares to customize the behavior of your ASGI application.Daemon Mode: Run Netix as a daemon to keep it running in the background, detached from the terminal.Status Monitoring: Schedule status checks to monitor the health of your ASGI server.InstallationYou can install Netix viapip, making it a breeze to get started:pipinstallnetixConfigurationAvailable Commands and OptionsYou can control and configure Netix using various command-line options when starting the server:--host: Listen host. Defaults to "127.0.0.1".--daemon: Start the daemon mode to run the server in the background. Use--daemon main:appor@app moduleto daemonize.--port: Listen port. Defaults to 8000.--bind: Address to bind. You can use this option instead of--hostand--port. For example, "127.0.0.1:8000" or "/tmp/file.sock".--reuse-port: UseSO_REUSEPORTwhen available.--worker-num: Number of worker processes. Defaults to 1.--backlog: Maximum number of pending connections. Defaults to 100.--ssl-cert: SSL certificate location. For example, "/path/to/fullchain.pem".--ssl-key: SSL private key location. For example, "/path/to/privkey.pem".--debug: Enable debug mode. Intended for development.--no-ws: Disable built-in WebSocket support.--log-level: Defaults to "DEBUG". For available log levels, seePython Logging Levels.--download-rate: Limits the sending speed to the client. Defaults to 1048576, which means 1 MiB/s.--upload-rate: Limits the upload / POST speed. Defaults to 1048576, which means 1 MiB/s.--buffer-size: Defaults to 16384, or 16 KiB.--client-max-body-size: Defaults to 2 * 1048576, or 2 MiB.--request-timeout: Defaults to 30 seconds.--keepalive-timeout: Defaults to 30 seconds.--keepalive-connections: Maximum number of keep-alive connections per worker. Defaults to 512 connections per worker.--root-path: Set the ASGI root_path. Defaults to an empty string.For example, you can run Netix with these options:python3-mnetix--debug--port8080example:app
python3-mnetix--daemonexample:app

ornetix--debug--port8080example:app
netix--daemonexample:appExampleRun the Lexan ASGI Framework App using Netix Server.$netix--bind127.0.0.1:8000example:appOutput:StartingNetixv1.11(cpython3.11.4,linux)------------------------------------------------------------------------
Settings:[host=127.0.0.1,port=8000,reuse_port=True,worker_num=1,ssl={},app=test:app,log_level=DEBUG]------------------------------------------------------------------------[2023-10-2123:02:39]StartingNetixASGIserverfor/\Aquilify[2023-10-2123:02:39,890]INFO:lifespan:startup[2023-10-2123:02:40]Netix(ASGI)(pid69334)isstartedat127.0.0.1:8000(PressCTRL+Ctoquit)