Tailscale with secrets

This commit is contained in:
pazpi 2024-09-11 22:50:08 +02:00
parent 8df20a270a
commit 94b9d49c66
No known key found for this signature in database
GPG key ID: 0942571C4B9966BE

View file

@ -1,10 +1,12 @@
{ { config
config, , pkgs
pkgs, , lib
lib, , home-manager
home-manager, , ...
...
}: }:
let
tailscaleMagicDNS = "neon-dory.ts.net";
in
{ {
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
@ -12,6 +14,15 @@
# home-manager.nixosModules.home-manager # home-manager.nixosModules.home-manager
]; ];
age = {
identityPaths = [ "/home/pazpi/.ssh/id_ed25519" ];
secrets = {
tailscale-authKey.file = ../../secrets/tailscale-authKey.age;
};
};
my = { my = {
desktop = { desktop = {
audio.enable = false; audio.enable = false;
@ -22,17 +33,34 @@
hashedPassword = "$y$j9T$dA94KVg1/jYLqclQQbTDk.$cnfxBWUN8P4shr8Kkipv5bU/RCtQNoAwYFDZ0X/BYs5"; hashedPassword = "$y$j9T$dA94KVg1/jYLqclQQbTDk.$cnfxBWUN8P4shr8Kkipv5bU/RCtQNoAwYFDZ0X/BYs5";
}; };
networking = {
enable = true;
hostname = "deadbeef";
localDNS = [ "192.168.1.2" ];
};
plymouth = { plymouth = {
enable = true; enable = true;
theme = "colorful_loop"; theme = "colorful_loop";
}; };
utils = { utils = {
commons.enable = true;
i18n.enable = true; i18n.enable = true;
}; };
}; };
utils = {
commons.enable = true;
};
networking = {
tailscale = {
enable = true;
magicDNSDomain = tailscaleMagicDNS;
authKeyFile = config.age.secrets.tailscale-authKey.path;
};
};
}; };
time.timeZone = "Europe/Rome"; time.timeZone = "Europe/Rome";