Update nix-darwin codex flake and switch config

This commit is contained in:
2026-04-18 11:33:40 -07:00
parent 8557b82a3b
commit 403fe0deef
7 changed files with 614 additions and 131 deletions

View File

@@ -152,6 +152,9 @@ in {
{}
// optionalAttrs (instance.token != null) {
TOKEN = instance.token;
}
// optionalAttrs (instance.tokenFile != null) {
TOKEN_FILE = toString instance.tokenFile;
};
RunAtLoad = true;
ProgramArguments = [
@@ -164,6 +167,10 @@ in {
'' else ""
}
if [ ! -e "/var/lib/gitea-runner/${name}/.runner" ]; then
if [ -z "''${TOKEN:-}" ]; then
echo "Missing registration token for ${name}" >&2
exit 1
fi
${cfg.package}/bin/act_runner register --no-interactive \
--instance ${escapeShellArg instance.url} \
--token "$TOKEN" \