summaryrefslogtreecommitdiffstats
path: root/lass/2configs/minecraft.nix
diff options
context:
space:
mode:
authorlassulus <lassulus@lassul.us>2020-10-29 19:27:11 +0100
committerlassulus <lassulus@lassul.us>2020-10-29 19:27:11 +0100
commit090ce70e7d089ea2c8d82d9170d0bb5ccde4b454 (patch)
treea26e4fed0dd5201011e791cd39e6bbc40bc1040d /lass/2configs/minecraft.nix
parentfbbee5daca66332179e1efed442764b26718cfbe (diff)
parent30f73aab5de2649c03f88c5e61715790ad9f1350 (diff)
Merge branch 'master' into 20.09
Diffstat (limited to 'lass/2configs/minecraft.nix')
-rw-r--r--lass/2configs/minecraft.nix22
1 files changed, 8 insertions, 14 deletions
diff --git a/lass/2configs/minecraft.nix b/lass/2configs/minecraft.nix
index 6f8ceb358..d2a3672c5 100644
--- a/lass/2configs/minecraft.nix
+++ b/lass/2configs/minecraft.nix
@@ -1,19 +1,13 @@
-{ pkgs, ... }:
+{ pkgs, ... }: let
-{
- users.users = {
- mc = {
- name = "mc";
- description = "user playing mc";
- home = "/home/mc";
- createHome = true;
- useDefaultShell = true;
- packages = with pkgs; [
- tmux
- ];
- };
+ unstable = import <nixpkgs-unstable> { config.allowUnfree = true; };
+
+in {
+ services.minecraft-server = {
+ enable = true;
+ eula = true;
+ package = unstable.minecraft-server;
};
- krebs.per-user.mc.packages = [ pkgs.jdk ];
krebs.iptables.tables.filter.INPUT.rules = [
{ predicate = "-p tcp --dport 25565"; target = "ACCEPT"; }
{ predicate = "-p udp --dport 25565"; target = "ACCEPT"; }