explaingit

nginx/unit

5,562CAudience · ops devopsComplexity · 4/5LicenseSetup · moderate

TLDR

NGINX Unit was an all-in-one web server that ran Python, PHP, Node.js, and other languages natively, now archived with development stopped and no new maintainer.

Mindmap

mindmap
  root((NGINX Unit))
    What it does
      All-in-one web server
      Runs code natively
      Live JSON config API
    Languages Supported
      Python PHP Node.js
      Ruby WebAssembly
    Key Features
      No restart needed
      Unix socket API
      unitctl CLI
    Status
      Archived project
      No new maintainer
    Install
      Debian Ubuntu Fedora
      Docker images
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Deploy a Python or PHP web app without a separate reverse proxy or process manager by using Unit as a single-process server.

USE CASE 2

Configure a running web server live via JSON API without restarting or editing config files on disk.

USE CASE 3

Run WebAssembly (WASI) server-side workloads sandboxed inside a web server.

Tech stack

CPythonPHPNode.jsRubyWebAssembly

Getting it running

Difficulty · moderate Time to first run · 30min

Project is archived, security vulnerabilities may go unaddressed, not recommended for new production deployments.

In plain English

NGINX Unit was a web server designed to run application code directly, without the separate process managers and reverse proxies that most web deployments require. Where a typical server setup involves one program to serve files, another to manage language runtimes like Python or PHP, and a third to route traffic between them, Unit aimed to do all of that in a single piece of software. It supported eight programming languages natively, including Python, PHP, Node.js, and Ruby. Important note: the repository has been archived and the README states that all development has stopped and security vulnerabilities may go unaddressed. The repository can still be cloned and used under its existing license, but no new maintainer has been announced. While active, Unit had a distinctive approach to configuration. Instead of editing text files and restarting a service, administrators configured it by sending JSON data to an API over a Unix socket. That API accepted changes and applied them immediately, without interrupting traffic in progress. The same API could be used to add a new application, adjust a listener, or inspect the current running configuration, all without touching a config file on disk. Installation was available through package managers on Debian, Ubuntu, Fedora, and Red Hat based systems, through Docker images with per-language variants, and through Homebrew on macOS. A command-line tool called unitctl provided a friendlier interface for starting instances, editing configuration interactively, and managing running processes. Unit also supported WebAssembly components using the WASI 0.2 standard, which allows code compiled from languages like Rust or C to run in a sandboxed environment on the server. An OpenAPI specification for the control API was included in the repository for developers building tooling around Unit. The code was made by the NGINX team, the same organization behind the widely used NGINX web server. It was released as open source.

Copy-paste prompts

Prompt 1
Show me a minimal NGINX Unit configuration JSON to run a Python Flask app on port 8080, what do I POST to the control socket?
Prompt 2
How do I migrate an existing NGINX + uWSGI Python deployment to NGINX Unit, and what are the equivalent config options?
Prompt 3
Walk me through using unitctl to start NGINX Unit, add a Node.js app, and reload config without dropping connections.
Prompt 4
What are the risks of using archived NGINX Unit in production today, and what are the best actively maintained alternatives?
Open on GitHub → Explain another repo

← nginx on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.