nix for hermes

This commit is contained in:
ari committed 2026-08-13 10:30:48 -04:00
1 parent e900bb4dfe
commit 33539144d8
6 files changed
+63

No files matched your search

+6
View File
@@ -3,6 +3,12 @@
A complete reference for an AI agent to understand, navigate, and modify this
NixOS homelab configuration repository.
> **⚠️ MANDATORY:** Before doing anything in this repository, read
> [`GUIDELINES.md`](../GUIDELINES.md) in full and follow it. It contains
> non-negotiable hard rules (never run builds, never edit `flake.lock`, etc.)
> and requires you to **present a plan and get user approval before making any
> changes**.
---
## Repository Purpose
+17
View File
@@ -0,0 +1,17 @@
# Agent Instructions
**MANDATORY FIRST ACTION:** Read [`GUIDELINES.md`](GUIDELINES.md) in full before
doing anything in this repository. It is the single source of truth for agent
behavior here.
Key non-negotiable rules from that file:
- **Always present a plan first** and wait for user approval before making any
changes — no matter how small the task.
- **Never run builds or system switches** (`nixos-rebuild`, `nh os`, `skyg os`,
`nix build`, `nix flake check`, etc.) — zero exceptions, even if asked.
- Never edit `flake.lock`, `*.hardware-configuration.nix`, or anything in
`secrets/`.
- Never add `imports = [...]` to host files.
- Never commit or create branches unless explicitly asked.
- Also read [`.agents/Agent.md`](.agents/Agent.md) for full repository context.
+17
View File
@@ -0,0 +1,17 @@
# Claude Instructions — nixos-setup
**MANDATORY FIRST ACTION:** Read [`GUIDELINES.md`](GUIDELINES.md) in full before
doing anything in this repository. It is the single source of truth for agent
behavior here.
Key non-negotiable rules from that file:
- **Always present a plan first** and wait for user approval before making any
changes — no matter how small the task.
- **Never run builds or system switches** (`nixos-rebuild`, `nh os`, `skyg os`,
`nix build`, `nix flake check`, etc.) — zero exceptions, even if asked.
- Never edit `flake.lock`, `*.hardware-configuration.nix`, or anything in
`secrets/`.
- Never add `imports = [...]` to host files.
- Never commit or create branches unless explicitly asked.
- Also read [`.agents/Agent.md`](.agents/Agent.md) for full repository context.
+14
View File
@@ -5,6 +5,20 @@ Read this file before making any changes.
---
## Mandatory First Step — Always Present a Plan
Before making **any** change to this repository, you MUST present a short plan to the user and wait for their approval. This applies to every task, no matter how small.
Your plan must include:
1. **What** you intend to change (files, options, packages)
2. **Why** the change is needed
3. **How** you will do it (which files you will edit, in what order)
4. **What you will NOT do** (e.g., "I will not run any builds")
Only after the user approves the plan may you proceed with edits.
---
## Hard Rules — Never Break These
### ❌ NEVER run builds or system switches — ZERO EXCEPTIONS
+6
View File
@@ -226,12 +226,18 @@ in
];
volumes = [
"/var/lib/hermes:/opt/data"
# Expose the host Nix store + daemon so nix works inside the container
"/nix/store:/nix/store:ro"
"/nix/var/nix/daemon-socket:/nix/var/nix/daemon-socket"
];
environmentFiles = [ config.age.secrets.hermes-env.path ];
environment = {
PUID = "1000";
PGID = "100";
HERMES_HOME = "/opt/data";
NIX_REMOTE = "daemon";
NIX_CONFIG = "experimental-features = nix-command flakes";
PATH = "${pkgs.nix}/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin";
};
shm_size = "1g";
extra_hosts = [ "host.docker.internal:host-gateway" ];
@@ -156,6 +156,7 @@ in
"--group-add=render"
"--security-opt=seccomp=unconfined"
"--ipc=host"
"--add-host=host.docker.internal:host-gateway"
];
environment = {
@@ -177,6 +178,8 @@ in
then [ "${cfg.rocm.outputDir}:/workspace/ComfyUI/output" ]
else [ "${cfg.rocm.dataDir}/output:/workspace/ComfyUI/output" ])
++ cfg.rocm.extraVolumes;
networks = [ "main" ];
};
# Ensure the container service starts after Docker image is built