Files
homelab/ansible/roles/multica_agent_host/tasks
JARVISandClaude Opus 5.5 94c77daf13 multica_agent_host: daemon lifecycle via systemd; fix login guard (WDWL-22)
Found provisioning spaceship-earth:

- Login was not idempotent: `multica auth status` prints to stderr (0.6.5),
  and the guard read stdout only, so every run re-logged in and restarted
  the daemon. The guard now reads both streams; the status read is no_log
  because it echoes a token prefix.
- `multica daemon start` / `daemon restart` fork the daemon inside the
  caller's session (Ansible's SSH session scope), outside the systemd user
  unit, which stays inactive: the same orphan seen on haunted-mansion on
  2026-10-21. Start/restart now go through `systemctl --user`, after a
  daemon-reload when autostart was (re)registered. A daemon found running
  outside its unit is stopped first. The unit name is read from
  `autostart status`, so --profile hosts resolve their own unit.

spaceship-earth: second run changed=0, daemon in multica-daemon.service.
Not yet run against haunted-mansion.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 16:04:46 -05:00
..
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00
2026-10-22 12:30:35 -05:00