diff options
| author | Martin Fischer <martin@push-f.com> | 2026-10-25 08:03:51 +0100 |
|---|---|---|
| committer | Martin Fischer <martin@push-f.com> | 2026-10-31 08:43:09 +0100 |
| commit | ebbbdf264eb5d26701012305eb53f2b295087fb6 (patch) | |
| tree | 3ddb29daf7a1c2bd4edb4f1c2ed233d1dbec7a22 /nixos/hosts/tente | |
| parent | b6d8aa299d47305a31a8dc88aae65aa29e6ab78e (diff) | |
refactor: move local service options under local.services
Diffstat (limited to 'nixos/hosts/tente')
| -rw-r--r-- | nixos/hosts/tente/default.nix | 16 | ||||
| -rw-r--r-- | nixos/hosts/tente/exporters.nix | 4 | ||||
| -rw-r--r-- | nixos/hosts/tente/git-web.nix | 4 | ||||
| -rw-r--r-- | nixos/hosts/tente/gitolite.nix | 4 | ||||
| -rw-r--r-- | nixos/hosts/tente/grafana.nix | 8 | ||||
| -rw-r--r-- | nixos/hosts/tente/headscale.nix | 4 | ||||
| -rw-r--r-- | nixos/hosts/tente/web-personal.nix | 4 |
7 files changed, 22 insertions, 22 deletions
diff --git a/nixos/hosts/tente/default.nix b/nixos/hosts/tente/default.nix index 085924f..5e7b278 100644 --- a/nixos/hosts/tente/default.nix +++ b/nixos/hosts/tente/default.nix @@ -95,17 +95,17 @@ in # comes with a pre-configured SSH jail services.fail2ban.enable = true; - gitolite = { + local.services.gitolite = { dataDir = gitoliteDataDir; user = "git"; group = "git"; }; - grafana = { + local.services.grafana = { port = ports.grafana; }; - headscale = { + local.services.headscale = { domain = "tailscale.${baseDomain}"; port = ports.headscale; }; @@ -142,12 +142,12 @@ in delaycompress = false; }; - web-personal = { + local.services.web-personal = { domain = baseDomain; dir = "/srv/www/${baseDomain}/current"; # not managed via Nix }; - gitWeb = { + local.services.git-web = { domain = "git.${baseDomain}"; reposDir = reposDir; user = "cgit"; @@ -229,7 +229,7 @@ in # Monitoring - exporters = { + local.services.exporters = { sqlExporterPort = ports.prometheusSqlExporter; storageboxExporterPort = ports.prometheusStorageboxExporter; }; @@ -253,7 +253,7 @@ in }; }; - monitoring = { + local.services.monitoring = { alloyUiPort = ports.grafanaAlloy; lokiPort = ports.grafanaLoki; lokiRetentionStream = [ @@ -309,7 +309,7 @@ in age.secrets.restic-db.file = ./secrets/restic-db.age; - restic-database-backups = { + local.services.restic-database-backups = { repository = "sftp://${backupHost}:23" + "/db"; passwordFile = config.age.secrets.restic-db.path; postgresDatabases = []; diff --git a/nixos/hosts/tente/exporters.nix b/nixos/hosts/tente/exporters.nix index 0eb9199..f5a719d 100644 --- a/nixos/hosts/tente/exporters.nix +++ b/nixos/hosts/tente/exporters.nix @@ -2,10 +2,10 @@ let helpers = import ../../shared/postgres-collectors.nix { inherit config lib pkgs; }; - cfg = config.exporters; + cfg = config.local.services.exporters; in { - options.exporters = { + options.local.services.exporters = { sqlExporterPort = lib.mkOption { type = lib.types.int; }; diff --git a/nixos/hosts/tente/git-web.nix b/nixos/hosts/tente/git-web.nix index 9271697..9e8063c 100644 --- a/nixos/hosts/tente/git-web.nix +++ b/nixos/hosts/tente/git-web.nix @@ -1,11 +1,11 @@ { config, lib, pkgs, ... }: let - cfg = config.gitWeb; + cfg = config.local.services.git-web; helpers = import ../../helpers.nix { inherit config lib pkgs; }; in { - options.gitWeb = { + options.local.services.git-web = { domain = lib.mkOption { type = lib.types.str; }; diff --git a/nixos/hosts/tente/gitolite.nix b/nixos/hosts/tente/gitolite.nix index f2959e5..4ded913 100644 --- a/nixos/hosts/tente/gitolite.nix +++ b/nixos/hosts/tente/gitolite.nix @@ -1,10 +1,10 @@ { config, lib, pkgs, ... }: let - cfg = config.gitolite; + cfg = config.local.services.gitolite; in { - options.gitolite = { + options.local.services.gitolite = { user = lib.mkOption { type = lib.types.str; }; diff --git a/nixos/hosts/tente/grafana.nix b/nixos/hosts/tente/grafana.nix index 3d7812c..250af83 100644 --- a/nixos/hosts/tente/grafana.nix +++ b/nixos/hosts/tente/grafana.nix @@ -1,12 +1,12 @@ { config, lib, pkgs, ... }: let - cfg = config.grafana; + cfg = config.local.services.grafana; ports = import ./ports.nix; evPorts = import ../ev/ports.nix; in { - options.grafana = { + options.local.services.grafana = { port = lib.mkOption { type = lib.types.int; }; @@ -42,13 +42,13 @@ in { name = "Prometheus Tente"; type = "prometheus"; - url = "http://${config.services.prometheus.listenAddress}:${toString config.monitoring.prometheusPort}"; + url = "http://${config.services.prometheus.listenAddress}:${toString config.local.services.monitoring.prometheusPort}"; } { name = "Loki Tente"; type = "loki"; access = "proxy"; - url = "http://127.0.0.1:${toString config.monitoring.lokiPort}"; + url = "http://127.0.0.1:${toString config.local.services.monitoring.lokiPort}"; } { name = "Prometheus Ev"; diff --git a/nixos/hosts/tente/headscale.nix b/nixos/hosts/tente/headscale.nix index 7b9544e..8ee82fa 100644 --- a/nixos/hosts/tente/headscale.nix +++ b/nixos/hosts/tente/headscale.nix @@ -1,10 +1,10 @@ { config, lib, pkgs, ... }: let - cfg = config.headscale; + cfg = config.local.services.headscale; in { - options.headscale = { + options.local.services.headscale = { port = lib.mkOption { type = lib.types.int; }; diff --git a/nixos/hosts/tente/web-personal.nix b/nixos/hosts/tente/web-personal.nix index 5bc6362..3d83176 100644 --- a/nixos/hosts/tente/web-personal.nix +++ b/nixos/hosts/tente/web-personal.nix @@ -1,11 +1,11 @@ { config, lib, pkgs, ... }: let - cfg = config.web-personal; + cfg = config.local.services.web-personal; helpers = import ../../helpers.nix { inherit config lib pkgs; }; in { - options.web-personal = { + options.local.services.web-personal = { domain = lib.mkOption { type = lib.types.str; }; |
