nix-conf/modules/servers/baldur/services/crafty-controller.nix
Crony Akatsuki 4e783c052b refactor: reorganize server modules
- Moved each individual service definition into a dedicated `services/`
  directory under every server module (e.g.
`modules/servers/bragi/services/`).
- Updated the corresponding `default.nix` files to import the renamed
  service modules from the new location.
- Applied the same changes across all server modules, ensuring
  the API and import paths remain consistent.
2026-01-19 19:21:11 +01:00

49 lines
1.2 KiB
Nix

{...}: {
virtualisation.oci-containers.containers.crafty-controller = {
image = "registry.gitlab.com/crafty-controller/crafty-4:latest";
autoStart = true;
ports = [
"8443:8443"
"8123:8123"
"19132:19132"
"25500-25600:25500-25600"
];
labels = {
"io.containers.autoupdate" = "registry";
};
volumes = [
"/var/lib/crafty-controller/backups:/crafty/backups"
"/var/lib/crafty-controller/logs:/crafty/logs"
"/var/lib/crafty-controller/servers:/crafty/servers"
"/var/lib/crafty-controller/config:/crafty/app/config"
"/var/lib/crafty-controller/import:/crafty/import"
];
};
networking.firewall = {
allowedTCPPorts = [25500];
allowedUDPPorts = [25500];
};
services.traefik.dynamicConfigOptions.http = {
services.crafty.loadBalancer.servers = [
{
url = "https://localhost:8443";
}
];
routers.crafty = {
rule = "Host(`crafty.cronyakatsuki.xyz`)";
tls = {
certResolver = "porkbun";
};
service = "crafty";
entrypoints = "websecure";
};
};
services.restic.backups = {
local.paths = ["/var/lib/crafty-controller"];
server.paths = ["/var/lib/crafty-controller"];
};
}