Update game-servers.nix

This commit is contained in:
ediblerope 2026-01-25 12:35:18 +00:00 committed by GitHub
parent b63c7f8a2a
commit 75eecd3381
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,30 +1,32 @@
#/services/game-servers.nix #/services/game-servers.nix
{ config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
{ {
config = lib.mkIf (config.networking.hostName == "FredOS-Mediaserver") { config = lib.mkIf (config.networking.hostName == "FredOS-Mediaserver") {
## <----- HYTALE ----> ## ## <----- HYTALE ----> ##
virtualisation.oci-containers = { virtualisation.oci-containers = {
backend = "docker"; backend = "docker";
containers."hytale" = { containers."hytale" = {
image = "ghcr.io/indifferentbroccoli/hytale-server-docker:latest"; image = "indifferentbroccoli/hytale-server-docker:latest";
ports = [ "5520:5520/udp" ]; autoStart = true;
environment = { ports = [ "5520:5520/udp" ];
SERVER_NAME = "Nordhammer.it Hytale Server"; environment = {
MAX_PLAYERS = "50"; SERVER_NAME = "Nordhammer.it Hytale Server";
MEMORY = "4G"; MAX_PLAYERS = "50";
ENABLE_BACKUP = "true"; MEMORY = "4G";
BACKUP_FREQUENCY = "30"; ENABLE_BACKUP = "true";
PASSWORD = "DukeSmells"; BACKUP_FREQUENCY = "30";
}; PASSWORD = "DukeSmells";
volumes = [ };
"/home/fred/docker/hytale-server/hytale-data:/home/hytale/server-files" volumes = [
]; "/home/fred/docker/hytale-server/hytale-data:/home/hytale/server-files"
extraOptions = [ ];
"--interactive=false" extraOptions = [
"--tty=false" "--stop-timeout=30"
]; "--interactive"
}; "--tty"
}; ];
networking.firewall.allowedUDPPorts = [ 5520 ]; };
}; };
networking.firewall.allowedUDPPorts = [ 5520 ];
};
} }