feat: Only load caddy after sops
All checks were successful
Flake checker / Build Nix targets (push) Successful in 9m29s

This commit is contained in:
uttarayan21
2025-08-16 14:49:58 +05:30
parent c4b939dff5
commit 973fb0c972
3 changed files with 24 additions and 0 deletions

View File

@@ -131,6 +131,26 @@
}
];
}
{
type = "openai-compatible";
name = "copilot";
api_key = "xxx"; # exchange your `ghu_` token at https://api.github.com/copilot_internal/v2/token with Bearer token
api_base = "https://api.githubcopilot.com";
patch = {
# Patch api
chat_completions = {
# Api type, possible values: chat_completions, embeddings, and rerank
".*" = {
# The regex to match model names, e.g. '.*' 'gpt-4o' 'gpt-4o|gpt-4-.*'
headers = {
# Patch request headers
"Copilot-Integration-Id" = "vscode-chat";
"Editor-Version:" = "aichat/0.1.0"; # optional
};
};
};
};
}
];
};
};

View File

@@ -35,6 +35,8 @@
systemd.services.caddy = {
serviceConfig = {
EnvironmentFile = config.sops.templates."HETZNER_API_KEY.env".path;
Requires = ["sops.service"];
After = ["sops.service"];
};
};
}

View File

@@ -40,6 +40,8 @@
systemd.services.caddy = {
serviceConfig = {
EnvironmentFile = config.sops.templates."HETZNER_API_KEY.env".path;
Requires = ["sops.service"];
After = ["sops.service"];
};
};
}