refactor(#1003): nixpkgs + nixpkgs-unstable as top-level meta inputs
Per mara's direction: both nixpkgs and nixpkgs-unstable are now
top-level meta flake inputs with explicit store-path URLs. Hyperhive
follows them rather than the other way around:
inputs.nixpkgs.url = "path:${pkgs.path}";
inputs.nixpkgs-unstable.url = "path:${nixpkgs-unstable}";
inputs.hyperhive.url = "...";
inputs.hyperhive.inputs.nixpkgs.follows = "nixpkgs";
inputs.hyperhive.inputs.nixpkgs-unstable.follows = "nixpkgs-unstable";
New NixOS host options (auto-set at build time, overridable):
services.hyperhive.c0re.nixpkgsFlake
default: "path:${pkgs.path}" — host's evaluated nixpkgs.
services.hyperhive.c0re.nixpkgsUnstableFlake
default: "path:${nixpkgs-unstable}" from hyperhive's flake.nix —
the channel that carries claude-code. Operators can override to
track a different unstable snapshot.
Legacy fallback (both args empty) preserved for backward compat.
Two new Rust tests cover the full-URL and fallback paths.
This commit is contained in:
parent
fe5a41288d
commit
db50da570a
10 changed files with 124 additions and 28 deletions
|
|
@ -59,6 +59,11 @@ pub struct Coordinator {
|
|||
/// "nixpkgs"` is set in the host flake). Empty string = legacy
|
||||
/// `follows = "hyperhive/nixpkgs"` behaviour.
|
||||
pub nixpkgs_flake: String,
|
||||
/// Store-path URL for `nixpkgs-unstable` to wire as a top-level meta
|
||||
/// flake input. Hyperhive's `inputs.nixpkgs-unstable` then follows it.
|
||||
/// Set via `--nixpkgs-unstable-flake` from `hive-c0re.nix`. Empty string
|
||||
/// falls back to the legacy `follows = "hyperhive/nixpkgs-unstable"`.
|
||||
pub nixpkgs_unstable_flake: String,
|
||||
/// TCP port the host's hive-c0re dashboard listens on. Inlined into
|
||||
/// each per-agent flake so the agent's web UI can build the right
|
||||
/// rebuild-button URL pointing back at the dashboard.
|
||||
|
|
@ -220,6 +225,7 @@ impl Coordinator {
|
|||
db_path: &Path,
|
||||
hyperhive_flake: String,
|
||||
nixpkgs_flake: String,
|
||||
nixpkgs_unstable_flake: String,
|
||||
dashboard_port: u16,
|
||||
operator_pronouns: String,
|
||||
context_window_tokens: std::collections::HashMap<String, u64>,
|
||||
|
|
@ -252,6 +258,7 @@ impl Coordinator {
|
|||
build_logs,
|
||||
hyperhive_flake,
|
||||
nixpkgs_flake,
|
||||
nixpkgs_unstable_flake,
|
||||
dashboard_port,
|
||||
operator_pronouns,
|
||||
context_window_tokens,
|
||||
|
|
|
|||
Loading…
Reference in a new issue