Commit Graph

4 Commits

Author SHA1 Message Date
cinereal
e5e85e40ed lib/services: allow overriding the base modules of configure
Consumers that supply their own portable service base -- a pinned
`service.nix` from a different nixpkgs, for example -- had no way to
replace the module that `configure` loads. Add a `baseModules`
parameter for that. It defaults to the portable service base, so
callers that only set `serviceManagerPkgs` are unaffected.

Assisted-by: Claude:claude-opus-5
Claude-Session: https://claude.ai/code/session_01DPPuohWjgbww5Rq8faiP57
2026-08-30 21:18:32 +02:00
cinereal
37bc26ef24 lib/services: expose portable service lib as lib.services
Followup to #506519. Adds `lib.services` so consumers can reference the
portable service infrastructure directly instead of using fragile
relative path imports.
2026-08-30 21:18:32 +02:00
cinereal
fb3b7c0b19 lib/services: improve configure function documentation
Expand the doc comment with a structured description, type signature,
properly formatted parameter docs, and an example showing how to
implement modular services for a new containing system.
2026-04-09 09:09:47 +02:00
cinereal
a338deb8a1 lib/services: move portable service infrastructure out of nixos/
Move the portable modular service base from
nixos/modules/system/service/portable/ to lib/services/, making it
importable by any module system (home-manager, nix-darwin) without
reaching into the nixos/ tree.

Moved files: service.nix, lib.nix, config-data.nix, config-data-item.nix,
test.nix. All external references updated (systemd/system.nix,
doc/manual/default.nix, assertions.nix, README.md).

No functional changes - only import paths differ.
2026-04-04 08:23:23 +02:00