summaryrefslogtreecommitdiffstats
path: root/configs/claude.nix
Commit message (Collapse)AuthorAgeFilesLines
* configs/claude: login, not between stateDir and its commenttv4 days1-4/+4
|
* configs/claude: the account's skills of no use here, offtv4 days1-1/+11
| | | | | | | | | The skills synced from the claude.ai account into ~/.claude/skills include documents (docx, pdf, pptx, xlsx, docs), browsers, desktop control, deep research and skill-creator, of no use to a remote, but listed to the model in every session: skillOverrides off in the managed settings, by each name, and as anthropic-skills:NAME, as sessions list them.
* configs/claude: the remotes' sessions named by --nametv4 days1-4/+3
| | | | | | claude remote-control --name NAME names its session in claude.ai, rather than CLAUDE_REMOTE_CONTROL_SESSION_NAME_PREFIX, the prefix of auto-generated names (NAME-...).
* configs/claude: the remotes wait for the logintv4 days1-4/+26
| | | | | | | | | | | | | Remote Control needs a login, and the units answer its questions in ~/.claude.json, which may come before it: so the units have ConditionPathExists on ~/.claude/.credentials.json (skipped, not failed, before the login), and a path unit on it starts the restore service, which starts the static remotes now, too, and the dynamic ones: at boot, if there's a login already, or else as soon as there is. The restore service isn't multi-user.target's anymore, and remains active, once done, so the path unit starts it once. claude-remote start refuses before the login, as the unit would be skipped, and forgotten.
* configs/claude: Remote Control's questions, answered by the unittv4 days1-4/+19
| | | | | | | | | | | | Remote Control asks two things: whether to enable it, once per machine (remoteDialogSeen in ~/.claude.json, which claude remote-control checks before it asks), and to trust ~/remotes/NAME, once per remote (projects.DIR.hasTrustDialogAccepted). The unit answers both now, before it starts: enabling it is what the units are for, and ~/remotes/NAME is the remote's own directory, just made. So, but for claude auth login, no remote needs an attach. Atomically, and only once there is a ~/.claude.json (after the login); if it fails, or a remote writes back what it read before, Remote Control asks, as before.
* configs/claude: a static remote taken out goes on, as a dynamic onetv4 days1-2/+17
| | | | | | | | | The restore service keeps the static remotes of each boot (in /home/.var/lib/claude/static-remotes); one that was static at the last boot, but isn't anymore, gets a state file, i.e. becomes dynamic, and starts again, as long as it has a directory. To retire one: claude-remote stop NAME, as for any dynamic one. The first boot with this only notes the static ones.
* configs/claude: git without gettexttv4 days1-1/+14
| | | | | | | | | git-minimal refers to gettext (25M) only for git-sh-i18n, which its shell scripts use for messages in other languages than English, which the guest has none of: the remotes' git and claude-remote's, built with nlsSupport = false (NO_GETTEXT), and without nixpkgs' postPatch putting gettext.sh's path into git-sh-i18n regardless. Not as an overlay of gitMinimal, which fetchers and builds use, too.
* configs/claude: claude-remote with the guest's systemdtv4 days1-0/+1
| | | | | | | | claude-remote got nixpkgs' systemd from callPackage, so with a slimmer one in the base system (firecracker's base/systemd.nix), the claude layer's image would carry the full one, too, for systemctl. Now it takes the guest's, as forget does already; with nixpkgs' systemd, nothing changes.
* configs/claude: the system's packages in the remotes' PATHtv5 days1-1/+3
| | | | | | | The remotes' PATH had only the packages of the service's path, so fc-egress, claude-remote, and anything else installed system-wide weren't there. Now /run/current-system/sw comes after them. claude's own packages stay the service's (packages, that is, not that string).
* configs/claude: claude-remote, root's tool for the remotestv5 days1-18/+13
| | | | | | | | | | | | | | | claude-remote list (the default) shows the remotes, static, dynamic, with a unit loaded, or with a directory, with their kind, state, and whether they trust their directory yet; inspect NAME shows a remote's unit, directory, trust, claude.ai session (bridge-pointer.json), and the last lines of its terminal; start, stop and restart NAME go through systemctl (a remote started here is dynamic: it lasts until stopped here), and start points to attach while the remote doesn't trust its directory; attach [NAME] opens its terminal (it's claude-attach, which is gone); log NAME shows its journal. Which remotes are static, it asks systemd (multi-user.target's wants), so changing them doesn't change it. A package (pkgs/claude-remote.nix), with bash completion of the commands and the remotes' names.
* configs/claude: sessions named after their remotetv5 days1-0/+3
| | | | | | Remote Control names the sessions it creates after the host, by default, which all remotes share. Now it names them after the remote (CLAUDE_REMOTE_CONTROL_SESSION_NAME_PREFIX), NAME-...
* configs/claude: remotes started with systemctl survive rebootstv5 days1-9/+61
| | | | | | | | | | | | | | A remote started with systemctl start claude-remote-control@NAME, rather than by multi-user.target's wants, now lasts until systemctl stop, across reboots: while it's meant to run, it has a file of its name in /home/.var/lib/claude/remote-control (the claude facet's part of what would be in /var/lib, which is on the tmpfs, on the home drive; root's), written when it starts (as root: ExecStartPre=+), and removed when it stops, but not by a failure (it restarts) nor by a shutdown (ExecStopPost=+, by SERVICE_RESULT and systemctl is-system-running). At boot, claude-remote-control-restore starts them again, but for those that are static by then, whose files it removes instead; static ones never get one.
* configs/claude: remotes, contexts on the repositories in ~/srctv5 days1-27/+39
| | | | | | | | | | | | | A Remote Control server per directory meant a context per directory of repositories, so two couldn't work on the same ones. Now claude-remote-control@NAME is a remote, a context of its own: it works in ~/remotes/NAME, its project for Claude Code (sessions, memory, trust), created if need be; and every remote works on the repositories in ~/src, an additional directory for all of them, by the machine's managed settings (/etc/claude-code/managed-settings.json, which also means for any claude here, and that nobody's own settings take it away). The default remote is main (it was @src), and claude-attach's default with it.
* configs/claude: a Remote Control server per directorytv5 days1-20/+42
| | | | | | | | | | | | claude-remote-control is a template now, claude-remote-control@DIR, one per directory in ~claude, created if need be (but not ~ itself, nor anything above it, nor a dot file): @src is the one there was, and another layer can add more to multi-user.target's wants. Each runs in a tmux of its own, /run/claude/DIR/tmux, in a runtime directory of its own: a second tmux new-session in the same server would exit without a process for systemd to follow (Type=forking), and stopping a unit removes its runtime directory. claude-attach takes the DIR (default: src).
* configs/claude: require nixtv6 days1-0/+7
| | | | | | | | | | run-firecracker-vm's guests no longer have nix unless they have its nix layer (layers/nix.nix). Claude builds and tries things with it (nix-build, nix-shell), so claude asserts that it's there, as in [ layers/nix.nix configs/claude.nix ], rather than coming up without. With it, the run script requires --store, as before only for the store to persist. hermes doesn't need nix: on its own, its store is read-only.
* configs: share claude-code, for layers on top of each othertv6 days1-19/+3
| | | | | | | | | claude and hermes each had their own claude-code and unfree predicate. On top of each other, the predicates don't add up, one replaces the other, and the claudes could drift apart with the next bump. Now both import modules/claude-code.nix, which the module system takes only once: claude-code, as pkgs.claude-code (an overlay), and its unfree predicate. The package stays the same store path.
* configs: fail the services without the home drivetv6 days1-0/+3
| | | | | | | RequiresMountsFor only requires home.mount if there is one, which the fc-home generator only makes with the drive (--home): without it, the services started anyway, with their state on the tmpfs. Now they assert that /home is a mount point, and fail otherwise.
* configs: fixed uids for claude and hermestv6 days1-0/+3
| | | | | | | | The guest creates its users anew at every boot (userborn's state is on the tmpfs), so a user's uid depended on which other users there were: another layer's user could take claude's 1000, and the files on the home drive would belong to someone else. claude keeps 1000, which its files have already; hermes, and its group, get 1001.
* configs: require --home, with hermes' home there, like claude'stv6 days1-1/+3
| | | | | | | | | | | | | | | Both layers set fc.home.required, so the run script refuses to start the guest without --home, instead of keeping the state on the tmpfs. hermes' home (stateDir) moves from the store drive to /home/hermes, where claude's is, too: the store drive is for the store, which should be fine to throw away, and the home drive keeps what can't be. Like claude's, the user's home doesn't get created with the user, as /home isn't mounted yet then; the module's tmpfiles create it, and hermes' services require the mount. To keep the existing state, once, with both drives attached: mv /nix/.rw-store/hermes /home/hermes
* configs/claude: same packages for user and servicetv6 days1-1/+1
|
* configs/claude: no telemetry, error reports, or claude.ai connectorstv6 days1-0/+9
| | | | | Denied by the egress list anyway: http-intake.logs.us5.datadoghq.com and mcp-proxy.anthropic.com.
* configs/claude.nix: inittv6 days1-0/+83
A Claude Code Remote Control server, on the Claude subscription, running as claude in a tmux which root opens with claude-attach.