diff --git a/nix/sets/ai-code.nix b/nix/sets/ai-code.nix index af61bab..7b99f0d 100644 --- a/nix/sets/ai-code.nix +++ b/nix/sets/ai-code.nix @@ -3,8 +3,9 @@ # Uses tryEval with meta.license check to handle both missing and unfree packages. { pkgs }: let + # claude-code is installed separately via npm (latest version, smaller footprint) + # — the nixpkgs package bundles sharp/libvips (~500MB) and lags behind releases. wanted = [ - "claude-code" "codex" "opencode" "aider-chat" diff --git a/src/runtime/incus.rs b/src/runtime/incus.rs index 000b444..df043a0 100644 --- a/src/runtime/incus.rs +++ b/src/runtime/incus.rs @@ -175,6 +175,14 @@ impl Runtime for IncusRuntime { run_ok("incus", &launch_args).await?; + // Expand the root disk to 20GB (Incus default is 10GB, too small for + // NixOS with dev tools). Must be done after launch, before provisioning. + let _ = run_ok( + "incus", + &["config", "device", "override", &vm, "root", "size=20GiB"], + ) + .await; + // Wait for the VM agent to be ready before provisioning. // The guest agent takes time to start after boot. println!("Waiting for VM agent to be ready..."); diff --git a/src/runtime/lima.rs b/src/runtime/lima.rs index 0ff9a3b..0378c0d 100644 --- a/src/runtime/lima.rs +++ b/src/runtime/lima.rs @@ -82,6 +82,7 @@ vmOpts: cpus: {cpu} memory: "{memory}" +disk: "20GiB" mounts: {mounts_yaml} diff --git a/src/sandbox/provision.rs b/src/sandbox/provision.rs index da20175..1899623 100644 --- a/src/sandbox/provision.rs +++ b/src/sandbox/provision.rs @@ -149,8 +149,8 @@ fn nix_packages_for_set(set: &str) -> Vec<&'static str> { "trippy", "doggo", ], + // claude-code is installed separately via npm (latest version, smaller footprint) "ai-code" => vec![ - "claude-code", "codex", "opencode", "aider-chat",