Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
Commit7ad26c17419e391c9ddf6cb15027882735754c90 (patch)
Author
 Syndamia <kamen@syndamia.com>
2026-01-27 20:36:41 +0200
Committer
 Syndamia <kamen@syndamia.com>
2026-01-27 20:36:41 +0200
Files329fdcf994b3cba6a2902d0ecdde75dde7cb789e
nix-7ad26c17419e391c9ddf6cb15027882735754c90.tar
nix-7ad26c17419e391c9ddf6cb15027882735754c90.tar.gz
nix-7ad26c17419e391c9ddf6cb15027882735754c90.zip
Parent98440b959f914b5a0be15d419adbb84523787541 (diff)
feat(machines/marduk): Add minecraft server config
4 files changed, 156 insertions, 33 deletions
-rw-r--r--flake.lock150
-rw-r--r--flake.nix8
-rw-r--r--machines/marduk/configuration.nix1
-rw-r--r--machines/marduk/minecraft.nix30
diff --git a/flake.lock b/flake.lock
index d7998ed..e95ee39 100644
--- a/flake.lock
+++ b/flake.lock
@@ -1,5 +1,21 @@
{
"nodes": {
+ "flake-compat": {
+ "flake": false,
+ "locked": {
+ "lastModified": 1747046372,
+ "narHash": "sha256-CIVLLkVgvHYbgI2UpXvIIBJ12HWgX+fjA8Xf8PUmqCY=",
+ "owner": "edolstra",
+ "repo": "flake-compat",
+ "rev": "9100a0f413b0c601e0533d1d94ffd501ce2e7885",
+ "type": "github"
+ },
+ "original": {
+ "owner": "edolstra",
+ "repo": "flake-compat",
+ "type": "github"
+ }
+ },
"flake-utils": {
"inputs": {
"systems": "systems"
@@ -18,18 +34,75 @@
"type": "github"
}
},
+ "flake-utils_2": {
+ "inputs": {
+ "systems": "systems_2"
+ },
+ "locked": {
+ "lastModified": 1731533236,
+ "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
+ "owner": "numtide",
+ "repo": "flake-utils",
+ "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
+ "type": "github"
+ },
+ "original": {
+ "owner": "numtide",
+ "repo": "flake-utils",
+ "type": "github"
+ }
+ },
+ "hytale": {
+ "inputs": {
+ "flake-utils": "flake-utils",
+ "nixpkgs": "nixpkgs"
+ },
+ "locked": {
+ "lastModified": 1769270593,
+ "narHash": "sha256-xk/p25XChk2XB6NRdayRuP17mfQh9JEroLmGVFbE1ow=",
+ "owner": "JPyke3",
+ "repo": "hytale-launcher-nix",
+ "rev": "da53ec38c153a385d13d7adc2fa7af23e8e642df",
+ "type": "github"
+ },
+ "original": {
+ "owner": "JPyke3",
+ "repo": "hytale-launcher-nix",
+ "type": "github"
+ }
+ },
+ "nix-minecraft": {
+ "inputs": {
+ "flake-compat": "flake-compat",
+ "flake-utils": "flake-utils_2",
+ "nixpkgs": "nixpkgs_2"
+ },
+ "locked": {
+ "lastModified": 1768962252,
+ "narHash": "sha256-HyWOOHcySV8rl36gs4+n0sxPinxpwWOgwXibfFPYeZ0=",
+ "owner": "Infinidoge",
+ "repo": "nix-minecraft",
+ "rev": "433cf697394104123e1fd02fa689534ac1733bfa",
+ "type": "github"
+ },
+ "original": {
+ "owner": "Infinidoge",
+ "repo": "nix-minecraft",
+ "type": "github"
+ }
+ },
"nixpkgs": {
"locked": {
- "lastModified": 1766736597,
- "narHash": "sha256-BASnpCLodmgiVn0M1MU2Pqyoz0aHwar/0qLkp7CjvSQ=",
- "owner": "nixos",
+ "lastModified": 1769018530,
+ "narHash": "sha256-MJ27Cy2NtBEV5tsK+YraYr2g851f3Fl1LpNHDzDX15c=",
+ "owner": "NixOS",
"repo": "nixpkgs",
- "rev": "f560ccec6b1116b22e6ed15f4c510997d99d5852",
+ "rev": "88d3861acdd3d2f0e361767018218e51810df8a1",
"type": "github"
},
"original": {
- "owner": "nixos",
- "ref": "nixos-25.11",
+ "owner": "NixOS",
+ "ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
@@ -50,25 +123,6 @@
"type": "github"
}
},
- "nixpkgs-hytale": {
- "inputs": {
- "flake-utils": "flake-utils",
- "nixpkgs": "nixpkgs_2"
- },
- "locked": {
- "lastModified": 1768587205,
- "narHash": "sha256-v7ah2f3jcQPRRYojiR9doCEySmEVjcxPP0xWqH0r0GM=",
- "owner": "JPyke3",
- "repo": "hytale-launcher-nix",
- "rev": "7aed53c28c134a8a8454217cebdb15035533f50d",
- "type": "github"
- },
- "original": {
- "owner": "JPyke3",
- "repo": "hytale-launcher-nix",
- "type": "github"
- }
- },
"nixpkgs-mint": {
"locked": {
"lastModified": 1660112028,
@@ -103,25 +157,42 @@
},
"nixpkgs_2": {
"locked": {
- "lastModified": 1768305791,
- "narHash": "sha256-AIdl6WAn9aymeaH/NvBj0H9qM+XuAuYbGMZaP0zcXAQ=",
- "owner": "NixOS",
+ "lastModified": 1748929857,
+ "narHash": "sha256-lcZQ8RhsmhsK8u7LIFsJhsLh/pzR9yZ8yqpTzyGdj+Q=",
+ "owner": "nixos",
"repo": "nixpkgs",
- "rev": "1412caf7bf9e660f2f962917c14b1ea1c3bc695e",
+ "rev": "c2a03962b8e24e669fb37b7df10e7c79531ff1a4",
"type": "github"
},
"original": {
- "owner": "NixOS",
+ "owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
+ "nixpkgs_3": {
+ "locked": {
+ "lastModified": 1766736597,
+ "narHash": "sha256-BASnpCLodmgiVn0M1MU2Pqyoz0aHwar/0qLkp7CjvSQ=",
+ "owner": "nixos",
+ "repo": "nixpkgs",
+ "rev": "f560ccec6b1116b22e6ed15f4c510997d99d5852",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nixos",
+ "ref": "nixos-25.11",
+ "repo": "nixpkgs",
+ "type": "github"
+ }
+ },
"root": {
"inputs": {
- "nixpkgs": "nixpkgs",
+ "hytale": "hytale",
+ "nix-minecraft": "nix-minecraft",
+ "nixpkgs": "nixpkgs_3",
"nixpkgs-2305": "nixpkgs-2305",
- "nixpkgs-hytale": "nixpkgs-hytale",
"nixpkgs-mint": "nixpkgs-mint",
"nixpkgs-unstable": "nixpkgs-unstable"
}
@@ -140,6 +211,21 @@
"repo": "default",
"type": "github"
}
+ },
+ "systems_2": {
+ "locked": {
+ "lastModified": 1681028828,
+ "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
+ "owner": "nix-systems",
+ "repo": "default",
+ "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
+ "type": "github"
+ },
+ "original": {
+ "owner": "nix-systems",
+ "repo": "default",
+ "type": "github"
+ }
}
},
"root": "root",
diff --git a/flake.nix b/flake.nix
index c8a7269..05e0c41 100644
--- a/flake.nix
+++ b/flake.nix
@@ -9,11 +9,17 @@
nixpkgs-mint.url = "github:nixos/nixpkgs/9217c8084d8bc067d48c8edf5768e9dc54962970"; # 10 Aug 2022
hytale.url = "github:JPyke3/hytale-launcher-nix";
+ nix-minecraft.url = "github:Infinidoge/nix-minecraft";
};
outputs = inputs:
let
- autoconfig = import ./autoconfig.nix { inherit inputs; };
+ autoconfig = import ./autoconfig.nix {
+ inherit inputs;
+ modules = [
+ inputs.nix-minecraft.nixosModules.minecraft-servers
+ ];
+ };
in {
nixosConfigurations = autoconfig.configurations;
inherit (autoconfig) packages;
diff --git a/machines/marduk/configuration.nix b/machines/marduk/configuration.nix
index 11fff30..bef2e93 100644
--- a/machines/marduk/configuration.nix
+++ b/machines/marduk/configuration.nix
@@ -4,6 +4,7 @@
imports = [
./mail.nix
./aim.nix
+ ./minecraft.nix
./kamen.nix
];
diff --git a/machines/marduk/minecraft.nix b/machines/marduk/minecraft.nix
new file mode 100644
index 0000000..083323d
--- /dev/null
+++ b/machines/marduk/minecraft.nix
@@ -0,0 +1,30 @@
+{ config, pkgs, ... }:
+with pkgs.nix-minecraft; {
+ services.minecraft-servers = {
+ enable = true;
+ eula = true;
+
+ openFirewall = true;
+ servers.test = {
+ enable = false;
+ jvmOpts = "-XX:+UseG1GC -Xms2048M -Xmx2048M";
+
+ package = vanillaServers.vanilla-1_14_2;
+
+ whitelist = {
+ Syndamia = "43974325-b17b-4bfb-b5ab-4854c38a9d0a";
+ };
+ operators = {
+ Syndamia = "43974325-b17b-4bfb-b5ab-4854c38a9d0a";
+ };
+
+ serverProperties = {
+ difficulty = 3;
+ gamemode = 0;
+ max-players = 5;
+ motd = "Test server!";
+ white-list = true;
+ };
+ };
+ };
+}