50. Nix o‘rnatilishi
OpenClaw’ni Nix bilan ishga tushirishning tavsiya etilgan usuli — nix-openclaw orqali, ya’ni barcha kerakli narsalarni o‘z ichiga olgan Home Manager moduli.Tezkor boshlash
Buni AI agentingizga (Claude, Cursor va boshqalar) joylashtiring:📦 Full guide: github.com/openclaw/nix-openclaw The nix-openclaw repo is the source of truth for Nix installation. This page is just a quick overview.
Nimalarga ega bo‘lasiz
- Gateway + macOS ilovasi + vositalar (whisper, spotify, cameras) — barchasi qat’iy versiyalarga biriktirilgan
- Qayta yuklashlardan keyin ham ishlashda davom etadigan Launchd xizmati
- Deklarativ konfiguratsiyaga ega plagin tizimi
- Bir zumda ortga qaytarish:
home-manager switch --rollback
Nix Mode Runtime Behavior
WhenOPENCLAW_NIX_MODE=1 is set (automatic with nix-openclaw):
OpenClaw supports a Nix mode that makes configuration deterministic and disables auto-install flows.
Enable it by exporting:
Config + state paths
OpenClaw JSON5 konfiguratsiyasiniOPENCLAW_CONFIG_PATH dan o‘qiydi va o‘zgaruvchan ma’lumotlarni OPENCLAW_STATE_DIR da saqlaydi.
Zarur bo‘lganda, ichki yo‘l aniqlashlari uchun ishlatiladigan asosiy uy katalogini boshqarish uchun OPENCLAW_HOME ni ham o‘rnatishingiz mumkin.
OPENCLAW_HOME(standart ustuvorlik:HOME/USERPROFILE/os.homedir())OPENCLAW_STATE_DIR(default:~/.openclaw)OPENCLAW_CONFIG_PATH(default:$OPENCLAW_STATE_DIR/openclaw.json)
Runtime behavior in Nix mode
- Auto-install and self-mutation flows are disabled
- Missing dependencies surface Nix-specific remediation messages
- UI surfaces a read-only Nix mode banner when present
Packaging note (macOS)
The macOS packaging flow expects a stable Info.plist template at:scripts/package-mac-app.sh copies this template into the app bundle and patches dynamic fields
(bundle ID, version/build, Git SHA, Sparkle keys). This keeps the plist deterministic for SwiftPM
packaging and Nix builds (which do not rely on a full Xcode toolchain).
Related
- nix-openclaw — full setup guide
- Wizard — non-Nix CLI setup
- Docker — containerized setup