minecraft

This commit is contained in:
Lucy von Overheidt 2025-09-14 01:17:31 +02:00
parent d6366c68c0
commit 60e885b1a4
3 changed files with 115 additions and 5 deletions

21
modules/minecraft.nix Normal file
View file

@ -0,0 +1,21 @@
{
lib,
...
}:
{
nixpkgs.config.allowUnfreePredicate =
pkg:
builtins.elem (lib.getName pkg) [
"minecraft-server"
];
services.minecraft-servers = {
enable = true;
eula = true;
openFirewall = true;
servers.vanilla = {
enable = true;
jvmOpts = "-Xmx4G -Xms2G";
};
};
}