Files
agentos/mkosi.extra/usr/lib/systemd/system/agent-setup@.service
T
Job79andClaude Opus 5.5 db8fb0d5a4 feat: root adds the ssh keys, mkosi ssh for the test VM
The setup no longer asks for an ssh key. Root logs in on the console and
adds keys for claude and root to /var/lib/agent. Root may log in with
ssh, and its home is a tmpfs that is wiped at every boot. The test VM
uses mkosi ssh instead of a forwarded port, so the agent.ssh-key
credential is gone.

Also mount /var with noatime, move STYLE.md into AGENTS.md and rewrite
comments to start with the name of what they describe.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-19 19:10:54 +01:00

26 lines
677 B
Desktop File

# First-boot setup
#
# Runs /usr/libexec/agent-setup on the screen (tty1) and the serial console
# (ttyS0) at once, so it can be answered on either. Whichever is answered first
# stops the other.
[Unit]
Description=Agent first-boot setup on %I
ConditionPathExists=!/var/lib/agent/hostname
After=systemd-tmpfiles-setup.service
Before=getty@%i.service serial-getty@%i.service
[Service]
Type=oneshot
ImportCredential=agent.*
ExecStart=/usr/libexec/agent-setup
StandardInput=tty
StandardOutput=tty
TTYPath=/dev/%I
TTYReset=yes
TTYVHangup=yes
# SuccessExitStatus counts being stopped by the other console as success.
SuccessExitStatus=SIGTERM
[Install]
WantedBy=multi-user.target