28 lines
434 B
Nix
28 lines
434 B
Nix
# Module: roles/minecraftserver
|
|
# Enables a Minecraft server on Docker
|
|
### THIS IS A TEMPORARY CONFIG
|
|
### WILL BE MIGRATED TO A FLAKE
|
|
{
|
|
config,
|
|
lib,
|
|
pkgs,
|
|
pkgsUnstable,
|
|
inputs,
|
|
...
|
|
}:
|
|
|
|
with lib;
|
|
|
|
let
|
|
cfg = config.minecraftserver;
|
|
in
|
|
{
|
|
options.minecraftserver = {
|
|
enable = mkEnableOption "Enables minecraftserver role";
|
|
};
|
|
|
|
config = mkIf cfg.enable {
|
|
networking.firewall.allowedTCPPorts = [ 25565 ];
|
|
};
|
|
}
|