diff --git a/hosts/oracle/default.nix b/hosts/oracle/default.nix index f34d32a..9758d53 100644 --- a/hosts/oracle/default.nix +++ b/hosts/oracle/default.nix @@ -78,5 +78,6 @@ nixpkgs.lib.nixosSystem { ../../modules/services/nextcloud.nix ../../modules/services/transmission.nix ../../modules/services/metrics.nix + ../../modules/gaming/minecraft-server.nix ]; } diff --git a/modules/gaming/minecraft-server.nix b/modules/gaming/minecraft-server.nix new file mode 100644 index 0000000..3da55a3 --- /dev/null +++ b/modules/gaming/minecraft-server.nix @@ -0,0 +1,32 @@ +{ ... }: { + + unfreePackages = [ "minecraft-server" ]; + + services.minecraft-server = { + enable = true; + eula = true; + declarative = true; + whitelist = { }; + openFirewall = true; + serverProperties = { + server-port = 25565; + difficulty = "normal"; + gamemode = "survival"; + white-list = false; + enforce-whitelist = false; + level-name = "world"; + motd = "Welcome!"; + pvp = true; + player-idle-timeout = 30; + generate-structures = true; + max-players = 20; + snooper-enabled = false; + spawn-npcs = true; + spawn-animals = true; + spawn-monsters = true; + allow-nether = true; + allow-flight = false; + }; + }; + +}