23 lines
502 B
Nix
23 lines
502 B
Nix
{config, ...}:
|
|
let
|
|
peerix_user = "peerix";
|
|
in
|
|
{
|
|
users.groups.${peerix_user} = {};
|
|
users.users.${peerix_user} = {
|
|
group = peerix_user;
|
|
isSystemUser = true;
|
|
};
|
|
|
|
age.secrets.binary-cache-secret = {
|
|
owner = peerix_user;
|
|
file = ../../secrets/binary-cache-secret.age;
|
|
};
|
|
|
|
services.peerix = {
|
|
enable = true;
|
|
user = peerix_user;
|
|
privateKeyFile = config.age.secrets.binary-cache-secret.path;
|
|
publicKey = (builtins.readFile ../../secrets/binary-cache-pub);
|
|
};
|
|
}
|