skillfed

dumb-init

Simple wrapper script which proxies signals to a child

dumb-init v1.2.5.post1 455.4K downloads/30d#6,559 on PyPI7,303
License unclear Active released

What it is and what it does

dumb-init is a statically-linked C binary deployed as a Python package that solves two critical problems when running applications as PID 1 inside containers. Normally, when a process becomes PID 1, the Linux kernel applies special signal handling rules: signals without explicit handlers are ignored rather than triggering default behavior, and orphaned zombie child processes are never reaped. This breaks graceful shutdown (SIGTERM has no effect) and leaves defunct processes accumulating in the container.

dumb-init runs as PID 1 and immediately spawns your actual application as a child process. It proxies all signals to that child, which then receives normal signal handling. By default it establishes a process session, so signals reach the entire process tree—useful for shell scripts that spawn background services. It also supports signal rewriting (e.g., converting SIGTERM to SIGQUIT for applications that require a specific stop signal) and can operate in single-child mode for transparent signal forwarding.

Use it for:

  • Docker containers running shell scripts or multiple background services that need proper signal propagation on shutdown
  • Kubernetes or Mesos deployments where the orchestrator sends standard signals but your app requires a different stop signal
  • Minimal container images where you want to avoid full init systems like systemd but still need correct process lifecycle handling
  • CI/CD pipelines where docker run commands need to cleanly terminate containers without leaving them running in the background

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

dumb-init is a minimal init system that runs as PID 1 in containers, properly handling signals and reaping zombie processes so your application receives clean signal delivery and graceful shutdown.

Yes, if you run containerized applications as PID 1 and need reliable signal handling and zombie reaping. The package is actively maintained, has no known vulnerabilities, and solves a real problem in container environments. Verify the license terms first if you have commercial or legal constraints.

Install

dumb-init on PyPI

pip

pip install dumb-init

uv

uv add dumb-init

poetry

poetry add dumb-init

Installing dumb-init

Before you install

Medium install friction due to platform-specific binary wheels (x86_64, aarch64, ppc64le, s390x). The package is actively maintained with recent commits and no known vulnerabilities, though the latest release was in 2022.

License in practice

License treatment is unclear from the package metadata, so you should verify the actual license terms in the GitHub repository before adopting it in a commercial or restricted context.

Quickstart

# Install via pip
pip install dumb-init

# In a Dockerfile, use as PID 1 entrypoint
ENTRYPOINT ["dumb-init", "--"]
CMD ["python", "app.py"]

# Or directly in shell scripts
#!/usr/bin/dumb-init /bin/sh
my-service &
my-other-service

Requires a Linux environment with glibc (manylinux wheels provided); not suitable for non-containerized or non-Linux deployments.

Verify before relying

  • Exact license terms and compatibility constraints for commercial use
  • Whether the package works on non-glibc Linux systems or musl-based containers

Package facts

License not declared (unclear)
Python support not specified
Install friction medium — platform-specific wheel
Runtime dependencies none
Maintenance actively maintained — 1,571 days since the last release
Last repo commit
First released
Downloads 455,381/month — #6,559 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: dumb_init-1.2.5.post1-py2.py3-none-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl; dumb_init-1.2.5.post1-py2.py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; dumb_init-1.2.5.post1-py2.py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl; dumb_init-1.2.5.post1-py2.py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl

Tags

container init systemdocker pid 1 signal handlingzombie process reapergraceful container shutdownsignal forwarding proxyminimal init for containers
container-initsignal-handlingdocker

More Utilities packages