nix-conf/nixos-modules/minecraft-server/default.nix

29 lines
684 B
Nix
Raw Normal View History

2023-12-30 23:39:33 +01:00
{ config, lib, ... }:
2023-07-26 21:00:43 +02:00
2024-07-10 23:02:54 +02:00
let
cfg = config.jopejoe1.minecraft-server;
in
{
2023-12-29 16:43:40 +01:00
options.jopejoe1.minecraft-server = {
enable = lib.mkEnableOption "Enable Bluetooth";
};
config = lib.mkIf cfg.enable {
services.minecraft-server = {
enable = true;
eula = true;
openFirewall = true;
declarative = true;
serverProperties = {
difficulty = 3;
enable-rcon = true;
"rcon.password" = "test";
2024-07-10 23:02:54 +02:00
motd = "\\u00A7cWake up to reality! Nothing ever goes as planned in this accursed world.";
2023-12-29 16:43:40 +01:00
spawn-protection = 0;
level-type = "minecraft:amplified";
level-name = "amplified_world";
};
2023-07-26 21:00:43 +02:00
};
};
}