Files
AZ-NIX-SERVERS/hosts/common/default.nix
T
m3ta-chironandClaude Fable 5.1 7385db3b09 feat(prm-1): align agent userspace of sascha.koenig with AZ-LT-NIX
- Import the m3ta-home agent modules (mcp, claude-code, opencode,
  ai-memory, claude-skills) in hosts/AZ-PRM-1/home.nix instead of the
  hand-rolled claude-code/opencode packages; Claude Code and OpenCode get
  the shared MCP catalogue, ai-memory hooks/MCP/skills, LiteLLM/Z.AI
  providers and the m3ta-chiron git identity
- Expose the flattened llm-agents packages additionally as pkgs.llm-agents
  so m3ta-home modules and the t3code-agent-identity overlay work here
- Apply m3ta-home's t3code-agent-identity overlay (T3 agents commit as
  m3ta-chiron), t3code service uses the wrapped module default package
- agent-lib-sync timer calls claude-skills-sync from the user profile
  instead of duplicating the link logic
- Secrets for AZ-PRM-1 (same values as AZ-LT-NIX): ai-memory-token,
  agent-gitea-token-{m3ta,az}; exa-key/ref-key now owned by sascha.koenig
- flake.lock: m3ta-home -> f4ab2ab (Claude MCP integration, PR #9)

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-10 20:16:23 +01:00

88 lines
2.5 KiB
Nix

# Common configuration for all hosts
{
config,
pkgs,
lib,
inputs,
outputs,
system,
...
}: {
imports = [
./extraServices
./users
./ports.nix
inputs.m3ta-nixpkgs.nixosModules.ports
inputs.home-manager.nixosModules.home-manager
];
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
extraSpecialArgs = {
inherit inputs outputs system;
videoDrivers = config.services.xserver.videoDrivers or [];
};
};
nixpkgs = {
# You can add overlays here
overlays = [
# Add overlays your own flake exports (from overlays and pkgs dir):
outputs.overlays.additions
outputs.overlays.modifications
outputs.overlays.unstable-packages
inputs.nur.overlays.default
inputs.m3ta-nixpkgs.overlays.default
(outputs.lib.mkLlmAgentsOverlay system)
# Wraps pkgs.llm-agents.t3code* with the agents' m3ta-chiron identity
# (same as AZ-NIX-CLIENTS). Must come AFTER mkLlmAgentsOverlay.
inputs.m3ta-home.overlays.t3code-agent-identity
# You can also add overlays exported from other flakes:
# neovim-nightly-overlay.overlays.default
# Or define it inline, for example:
# (final: prev: {
# hi = final.hello.overrideAttrs (oldAttrs: {
# patches = [ ./change-hello-to-hi.patch ];
# });
# })
];
# Configure your nixpkgs instance
config = {
# Disable if you don't want unfree packages
allowUnfree = true;
};
};
nix = {
settings = {
experimental-features = "nix-command flakes";
# Binärcache von numtide/llm-agents.nix (claude-code, opencode, t3code,
# codex ...). Ohne ihn werden diese Pakete lokal gebaut (codex = Rust).
substituters = ["https://cache.numtide.com"];
trusted-public-keys = ["niks3.numtide.com-1:DTx8wZduET09hRmMtKdQDxNNthLQETkc/yaX7M4qK0g="];
trusted-users = [
"root"
"sascha.koenig"
"jannik.mueller"
]; # Set users that are allowed to use the flake command
};
gc = {
automatic = true;
options = "--delete-older-than 30d";
};
optimise.automatic = true;
registry =
(lib.mapAttrs (_: flake: {inherit flake;}))
((lib.filterAttrs (_: lib.isType "flake")) inputs);
nixPath = ["/etc/nix/path"];
};
# AZ-NIX-9aj: nicht-interaktive Aktivierung (Colmena-apply, Wartung).
# Vertretbar: sshd key-only auf Port 2022, PasswordAuthentication off.
security.sudo.wheelNeedsPassword = false;
}