feat(networking): use client-id and client-secret for tailscale auth

This commit is contained in:
Mohammad Rafiq 2025-06-30 03:43:37 +08:00
parent c3acffe2bc
commit 2b97ee96ca
No known key found for this signature in database
3 changed files with 9 additions and 5 deletions

View file

@ -95,7 +95,6 @@ in
age.sshKeyPaths = [ "/persist/home/rafiq/.ssh/id_ed25519" ];
secrets = {
"keys/openrouter" = { };
"keys/tailscale" = { };
"keys/gemini" = { };
"keys/cvt-jira" = { };
"keys/cloudflare" = { };
@ -104,6 +103,8 @@ in
"rafiq/hashedPassword".neededForUsers = true;
"rafiq/personalEmailPassword" = { };
"rafiq/workEmailPassword" = { };
"tailscale/client-id" = { };
"tailscale/client-secret" = { };
};
};
environment.shellInit = # sh

View file

@ -17,7 +17,8 @@ in
services.tailscale = {
enable = true;
authKeyFile = config.sops.secrets."keys/tailscale".path;
authKeyFile = config.sops.secrets."tailscale/client-secret".path;
authKeyParameters.preauthorized = true;
};
persistDirs = singleton "/var/lib/tailscale";
}