Compare commits
6 commits
b17ac84693
...
a66eac3b17
Author | SHA1 | Date | |
---|---|---|---|
Tristan Daniël Maat | a66eac3b17 | ||
Tristan Daniël Maat | 6bc37ebdae | ||
Tristan Daniël Maat | 4fe3b8b22b | ||
Tristan Daniël Maat | 64057828cb | ||
Tristan Daniël Maat | b7d0d7521c | ||
Tristan Daniël Maat | 6b85b9523c |
|
@ -20,6 +20,8 @@
|
||||||
trustedUsers = [ "@wheel" ];
|
trustedUsers = [ "@wheel" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
boot.kernelParams = [ "highres=off" "nohz=off" ];
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
hostName = "tlaternet";
|
hostName = "tlaternet";
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ allow-nether=true
|
||||||
broadcast-console-to-ops=true
|
broadcast-console-to-ops=true
|
||||||
broadcast-rcon-to-ops=true
|
broadcast-rcon-to-ops=true
|
||||||
difficulty=normal
|
difficulty=normal
|
||||||
enable-command-block=false
|
enable-command-block=true
|
||||||
enable-jmx-monitoring=false
|
enable-jmx-monitoring=false
|
||||||
enable-query=false
|
enable-query=false
|
||||||
enable-rcon=false
|
enable-rcon=false
|
||||||
|
|
|
@ -90,6 +90,7 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
extraOptions = [ "--cpus=1.0" ];
|
||||||
autoStart = false;
|
autoStart = false;
|
||||||
ports = [ "25565:25565" ];
|
ports = [ "25565:25565" ];
|
||||||
volumes = [
|
volumes = [
|
||||||
|
@ -101,4 +102,31 @@ in {
|
||||||
"${whitelist}:/var/lib/minecraft/whitelist.json:ro"
|
"${whitelist}:/var/lib/minecraft/whitelist.json:ro"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
systemd.timers.podman-minecraft-voor-kia-off = {
|
||||||
|
description = "Turns off the minecraft server every day at 4 am";
|
||||||
|
wantedBy = [ "podman-minecraft-voor-kia.service" ];
|
||||||
|
timerConfig = {
|
||||||
|
Unit = "podman-minecraft-voor-kia-starter@stop.service";
|
||||||
|
OnCalendar = "04:00:00";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.timers.podman-minecraft-voor-kia-on = {
|
||||||
|
description = "Turns on the minecraft server every day at 2 pm";
|
||||||
|
wantedBy = [ "podman-minecraft-voor-kia.service" ];
|
||||||
|
timerConfig = {
|
||||||
|
Unit = "podman-minecraft-voor-kia-starter@start.service";
|
||||||
|
OnCalendar = "14:00:00";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.services."podman-minecraft-voor-kia-starter@" = {
|
||||||
|
description = "Unit to stop/start the minecraft server";
|
||||||
|
serviceConfig = {
|
||||||
|
ExecStart =
|
||||||
|
"${pkgs.systemd}/bin/systemctl %i podman-minecraft-voor-kia.service";
|
||||||
|
Type = "oneshot";
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
18
flake.lock
18
flake.lock
|
@ -2,11 +2,11 @@
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1622445595,
|
"lastModified": 1629481132,
|
||||||
"narHash": "sha256-m+JRe6Wc5OZ/mKw2bB3+Tl0ZbtyxxxfnAWln8Q5qs+Y=",
|
"narHash": "sha256-JHgasjPR0/J1J3DRm4KxM4zTyAj4IOJY8vIl75v/kPI=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "7d706970d94bc5559077eb1a6600afddcd25a7c8",
|
"rev": "997f7efcb746a9c140ce1f13c72263189225f482",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -37,11 +37,11 @@
|
||||||
},
|
},
|
||||||
"nixos-hardware": {
|
"nixos-hardware": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1623143341,
|
"lastModified": 1629744693,
|
||||||
"narHash": "sha256-a8NjpJVvJkb3ehu/KP1OaWwlRexom2D7lQEH5uCO9yA=",
|
"narHash": "sha256-guZxgF5v8Avqpdu5M/F3ygZ4f67Y6ruS7y2kA5yUhZE=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixos-hardware",
|
"repo": "nixos-hardware",
|
||||||
"rev": "fccbee72df707c3fb074854668deee6e1ff02351",
|
"rev": "de40acde6c056a7c5f3c9ad4dca0c172fa35d207",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -53,11 +53,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1622922048,
|
"lastModified": 1629379628,
|
||||||
"narHash": "sha256-nTyKxe0n7l/4HSmYaIN+63WQrvHrTJY6drSwP7bMqhU=",
|
"narHash": "sha256-dI8wpEo7wIVWoTUk2oyWFUnlVHNKLs+ren1TqITN1mI=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "5de44c15758465f8ddf84d541ba300b48e56eda4",
|
"rev": "a1007637cea374bd1bafd754cfd5388894c49129",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -7,6 +7,7 @@ let
|
||||||
mirror = "https://files.minecraftforge.net/maven/net/minecraftforge/forge";
|
mirror = "https://files.minecraftforge.net/maven/net/minecraftforge/forge";
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "${mirror}/${version}/forge-${version}-installer.jar";
|
url = "${mirror}/${version}/forge-${version}-installer.jar";
|
||||||
|
curlOpts = "--globoff";
|
||||||
# Forge doesn't seem to like newer shas
|
# Forge doesn't seem to like newer shas
|
||||||
sha1 = "e97821e5431bdcaa46e12048769922e2cdb5e2e1";
|
sha1 = "e97821e5431bdcaa46e12048769922e2cdb5e2e1";
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue