a893b0d817
mkosi only mounts live-image/ as /work/src, so the postinst couldn't reach the repo-root bin/vetting-agent.linux-amd64 — the build failed in CI with `install: cannot stat '/work/src/bin/vetting-agent.linux-amd64'`. The Makefile now copies the prebuilt agent into mkosi.extra/, which mkosi merges into the image root automatically. The postinst is reduced to creating the multi-user.target.wants symlink. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
11 lines
492 B
Bash
Executable File
11 lines
492 B
Bash
Executable File
#!/bin/sh
|
|
# mkosi postinst: enable the vetting-agent service. The binary lands in
|
|
# the image via mkosi.extra/ (staged by the live-image Makefile from
|
|
# ../bin/vetting-agent.linux-amd64); the service unit lands via
|
|
# mkosi.skeleton/. All we need here is the multi-user.target symlink.
|
|
set -eu
|
|
|
|
mkdir -p "$BUILDROOT/etc/systemd/system/multi-user.target.wants"
|
|
ln -sf /etc/systemd/system/vetting-agent.service \
|
|
"$BUILDROOT/etc/systemd/system/multi-user.target.wants/vetting-agent.service"
|