From 2533ecf1a2e82bc281775a156944014007d96ef5 Mon Sep 17 00:00:00 2001 From: kaffa Date: Tue, 9 Jun 2026 17:10:58 +0900 Subject: [PATCH] =?UTF-8?q?infra:=20hermes=20NixOS=20=EC=BB=A8=ED=85=8C?= =?UTF-8?q?=EC=9D=B4=EB=84=88=20=EC=A0=95=EB=B3=B8=20=EC=B6=94=EA=B0=80=20?= =?UTF-8?q?(hp2,=20Hermes=20Agent=20+=20Codex=20=EB=B0=B1=EC=97=94?= =?UTF-8?q?=EB=93=9C)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- infra/compute/hermes.md | 62 ++++++++++++++++++++++++++++++++ infra/compute/hosts/incus-hp2.md | 1 + 2 files changed, 63 insertions(+) create mode 100644 infra/compute/hermes.md diff --git a/infra/compute/hermes.md b/infra/compute/hermes.md new file mode 100644 index 0000000..aadfb9f --- /dev/null +++ b/infra/compute/hermes.md @@ -0,0 +1,62 @@ +--- +title: hermes +updated: 2026-06-09 +tags: [infra, incus, nixos, hermes, agent, seoul] +type: container +host_kind: container +location: seoul +provider: self-hosted +status: active +parent_host: incus-hp2 +incus_project: default +tailscale_ip: null +lan_ip: 10.100.2.77 +os: NixOS 25.11 +cpu_cores: 2 +ram_gb: 4 +disk_gb: 20 +monthly_cost_usd: 0 +--- + +## 개요 + +[[incus-hp2]] `default` 프로젝트의 **NixOS incus 컨테이너**. NousResearch **Hermes Agent**(self-improving 자율 AI 에이전트, persistent memory, 멀티채널 게이트웨이)를 호스팅한다. macmini(주 개발기)의 민감 데이터(SSH 키·Vault·nixos-infra)와 분리하기 위해 격리 컨테이너로 운영. NixOS 동류는 [[zlambda]]. + +## 인프라 + +| 항목 | 값 | +|---|---| +| 호스트 | [[incus-hp2]] (`default` 프로젝트) | +| OS | NixOS 25.11 (Xantusia), channel 기반 | +| IP | 10.100.2.77 (eth0, 10.100.2.0/24) | +| 스펙 | 2 vCPU / 4GB RAM / 20GB disk | +| 생성 | 2026-06-09, `images:nixos/25.11` | + +## Hermes Agent + +- 버전: v0.16.0 (2026.6.5) +- 설치: `/usr/local/lib/hermes-agent`, config `/root/.hermes/`, 런처 `/usr/local/bin/hermes` +- **백엔드: OpenAI Codex OAuth (ChatGPT Plus 구독)** — API 키 종량제가 아닌 구독 정액제. provider `openai-codex`, 모델 `gpt-5.4` +- 인증 토큰: `/root/.hermes/auth.json` (device_code OAuth). **구독 계정/시크릿은 컨테이너 로컬, repo·Obsidian에 평문 없음** +- 검증: `hermes -z '...'` 단발 추론 정상 응답 확인 (2026-06-09) + +## NixOS 설정 (정본) + +선언적 정본은 Gitea `kaffa/nixos-infra` → `hosts/hermes/configuration.nix`. 적용 절차: + +1. repo의 `hosts/hermes/configuration.nix`를 컨테이너 `/etc/nixos/configuration.nix`로 push +2. `incus exec hp2:hermes -- nixos-rebuild switch` + +핵심 설정: +- `programs.nix-ld.enable = true` — uv가 받는 prebuilt(standalone) Python·Node 바이너리가 NixOS에서 동작하게 함. Hermes 구동의 필수 전제. +- `nix.settings.sandbox = false` — incus(비특권) 컨테이너는 user namespace 제약으로 nix 빌드 sandbox 불가 +- `environment.extraInit`로 `/usr/local/bin`을 PATH에 추가 (Hermes 런처 위치) +- 의존성: `git curl cacert nodejs_22 python311 uv ripgrep ffmpeg` + +⚠️ **flake 미통합**: nixos-infra flake는 nixpkgs-25.05 핀, hermes는 25.11 타깃이라 현재 channel 기반으로만 빌드. flake 통합(별도 25.11 input + `nixosConfigurations.hermes`)은 향후 정리 과제. + +## 관련 + +- [[incus-hp2]] — 부모 호스트 +- [[zlambda]] — NixOS 동류 (flake 기반 베어메탈) +- [[infra-hosts]] — 인프라 토폴로지 정본 diff --git a/infra/compute/hosts/incus-hp2.md b/infra/compute/hosts/incus-hp2.md index 9f94598..8241e7f 100644 --- a/infra/compute/hosts/incus-hp2.md +++ b/infra/compute/hosts/incus-hp2.md @@ -29,6 +29,7 @@ Incus + K3s 워커 호스트 (서울존). 홈랩 bare-metal 서버. Incus 프로 - K3s Pod 42개 (2026-04-13 기준): APISIX, Gitea, Outline, VictoriaMetrics, n8n, Teleport 등 - Longhorn storage replica 참여 - Incus VM: `gitea-runner`, `juice-shop`, `k8s` 등 +- Incus 컨테이너: [[hermes]] (NixOS 25.11, NousResearch Hermes Agent, 2026-06-09 생성) ## 네트워크