Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Various Contexts

NixOS Compose tracks the state of the process within variables suffixed with ctx, of various Context types.

Context

Located in nixos_compose/context.py.

This is the main context scope of this tool. It contains various general variables & functions (such as logging).

  • Some parts are initially filled in the root entrypoint.
  • Some others are filled within the process.

This also stores working variables, such as composition & deployment content.

DriverContext

Located in nixos_compose/contexts/driver.py.

This tracks the parameters for Driver invocations.

StartContext

Located in nixos_compose/contexts/start.py.

This tracks the parameters for start invocations.

HTTPDContext

Located in nixos_compose/contexts/httpd.py.

This keeps track of the status of HTTP Deamon, used for extended kernel deployments.

It can be passed around, but is mostly accessed thru StartContext (as it is used in the start process)