blob: c99db214d8c2aaf467737663612913c7a7f3291d (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
# nixery.dev backing host in ru-central1-b
{ depot, lib, pkgs, ... }: # readTree options
{ config, ... }: # passed by module system
let
mod = name: depot.path.origSrc + ("/ops/modules/" + name);
in
{
imports = [
(mod "known-hosts.nix")
(mod "nixery.nix")
(mod "tvl-users.nix")
(mod "www/nixery.dev.nix")
(mod "yandex-cloud.nix")
(depot.third_party.agenix.src + "/modules/age.nix")
];
networking = {
hostName = "nixery-01";
domain = "tvl.fyi";
firewall.allowedTCPPorts = [ 22 80 443 ];
};
security.sudo.extraRules = lib.singleton {
groups = [ "wheel" ];
commands = [{ command = "ALL"; options = [ "NOPASSWD" ]; }];
};
services.depot.nixery.enable = true;
# Automatically collect garbage from the Nix store.
services.depot.automatic-gc = {
enable = true;
interval = "1 hour";
diskThreshold = 25; # GiB
maxFreed = 150; # GiB
preserveGenerations = "30d";
};
}
|