Add initial configuration files and validation scripts for NixOS setup

This commit is contained in:
Root User 2026-04-06 00:08:14 +03:00
parent a9a857b460
commit a86437d4b2
Signed by: root
GPG key ID: 087F0A95E5766D72
2 changed files with 14 additions and 10 deletions

View file

@ -73,9 +73,13 @@
"nixos-minecraft" = nixpkgs.lib.nixosSystem { "nixos-minecraft" = nixpkgs.lib.nixosSystem {
inherit system; inherit system;
modules = [ modules = [
./nix-system-configs/modules/system/minecraft.nix # Apply the overlay first so pkgs in later modules (like our local
# `minecraft.nix`) see the extra helpers provided by the overlay
{ nixpkgs.overlays = [ inputs.nix-minecraft.overlay ]; }
nix-minecraft.nixosModules.minecraft-servers nix-minecraft.nixosModules.minecraft-servers
{nixpkgs.overlays = [inputs.nix-minecraft.overlay];}
./nix-system-configs/modules/system/minecraft.nix
]; ];
}; };
}; };

View file

@ -7,12 +7,10 @@
choose = paths: builtins.head (builtins.filter (p: builtins.pathExists p) paths); choose = paths: builtins.head (builtins.filter (p: builtins.pathExists p) paths);
# Domain and Cloudflare DDNS records configured here. Update this list to add/remove records. # Domain and Cloudflare DDNS records configured here. Update this list to add/remove records.
domain = "prg-radio.org"; domain = "prg-radio.org";
modpack = pkgs.fetchModrinthModpack { # Try to use the nix-minecraft helper if the overlay is present; otherwise
# Get file from local system # fall back to a local path. If you use the fallback, ensure the path is an
src = /srv/minecraft/modpacks/AllTheMods10-prg.mrpack; # unpacked modpack directory with `mods` and `config` subdirectories.
packHash = "sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA="; modpack = /srv/minecraft/modpacks/AllTheMods10-prg.mrpack;
side = "server";
};
in { in {
options.local = { options.local = {
hostname = lib.mkOption { hostname = lib.mkOption {
@ -129,10 +127,12 @@ in {
}; };
symlinks = { symlinks = {
"mods" = "${modpack}/mods"; "mods" = "${modpack}/overrides/mods";
}; };
files = { files = {
"config" = "${modpack}/config"; "config" = "${modpack}/overrides/config";
"kubejs" = "${modpack}/overrides/kubejs";
"datapacks" = "${modpack}/overrides/datapacks";
}; };
}; };