mirror of
https://codeberg.org/muon/home.git
synced 2025-12-06 16:17:46 +00:00
35 lines
739 B
Nix
35 lines
739 B
Nix
{ pkgs, lib, config, inputs, ... }: {
|
|
options.mods.unfree.minecraft = {
|
|
enable = lib.mkEnableOption {
|
|
default = false;
|
|
description = "enables minecraft";
|
|
};
|
|
packages = lib.mkOption {
|
|
default = [
|
|
"minecraft-server"
|
|
];
|
|
description = "unfree packages";
|
|
};
|
|
};
|
|
|
|
imports = [
|
|
inputs.nix-minecraft.nixosModules.minecraft-servers
|
|
];
|
|
|
|
config = lib.mkIf config.mods.unfree.minecraft.enable {
|
|
nixpkgs.overlays = [
|
|
inputs.nix-minecraft.overlay
|
|
];
|
|
|
|
environment.systemPackages = with pkgs;
|
|
if config.mods.xorg.enable then
|
|
[ prismlauncher ]
|
|
else
|
|
[];
|
|
|
|
services.minecraft-servers = {
|
|
enable = true;
|
|
eula = true;
|
|
};
|
|
};
|
|
}
|