NixOS
Overview
NixOS is a Linux distribution built around the Nix package manager and a declarative configuration model. First released in 2003 by Eelco Dolstra, it is the most prominent example of a declarative operating system.
In NixOS, the entire system configuration is defined in a single declarative file (configuration.nix). The system is reproducible, reliable, and atomic — any change can be rolled back instantly.
Key Features
- Declarative configuration: System state is defined in
configuration.nix— the source of truth. - Nix package manager: Pure functional package management; each package is isolated in
/nix/store. - Atomic upgrades: Upgrades are atomic — if something fails, you can reboot to the previous generation.
- Reproducibility: Identical configurations produce identical systems.
- Rollback: Every boot entry is a previous system generation; instant rollback on failure.
- Nix expressions (Nixpkgs): Over 80,000 packages in the Nixpkgs repository.
- Container and VM support: Native support for building containers and VMs with Nix.
Licensing
Primarily GPL and other FOSS licenses. Nixpkgs uses a mix of licenses (mostly permissive).
Notable Facts
- NixOS’s Nix language is a purely functional language designed for package management.
- The /nix/store uses content-addressed paths — no package conflicts are possible.
- Home Manager extends NixOS to manage user environments declaratively.
- NixOS is popular among developers, DevOps engineers, and researchers for reproducibility.
Use Cases
- Developer workstations with reproducible environments
- CI/CD infrastructure
- Cloud deployments (NixOS can run in containers/VMs)
- Research environments requiring reproducibility
- Configuration management at scale
Related Technologies
- Docker
- Terraform
- Ansible
- GuixSD — GNU project with similar declarative model
- Nix — the underlying package manager
Official Resources
- Website: https://nixos.org/
- Documentation: https://nixos.wiki/
- Nixpkgs: https://github.com/NixOS/nixpkgs
- Nix language manual: https://nix.dev/manual/nix/language