diff --git a/hosts/aristotle/default.nix b/hosts/aristotle/default.nix index 8add9bc..27b09dd 100644 --- a/hosts/aristotle/default.nix +++ b/hosts/aristotle/default.nix @@ -18,4 +18,6 @@ networking.hostName = "aristotle"; time.timeZone = "Asia/Shanghai"; _module.args.disks = ["/dev/nvme0n1"]; # Disko + + services.tailscale.enable = true; } diff --git a/hosts/blacksteel/anti-feature.nix b/hosts/blacksteel/anti-feature.nix index 6941724..243c862 100644 --- a/hosts/blacksteel/anti-feature.nix +++ b/hosts/blacksteel/anti-feature.nix @@ -14,6 +14,7 @@ "sof-firmware" "spotify" "vscodium" + "papermc" ]; allowUnfree = false; @@ -22,6 +23,7 @@ "nvidia-x11" "spotify" "broadcom-sta" + "papermc" ]; }; } diff --git a/hosts/blacksteel/default.nix b/hosts/blacksteel/default.nix index d801d08..58aa4e7 100644 --- a/hosts/blacksteel/default.nix +++ b/hosts/blacksteel/default.nix @@ -1,4 +1,4 @@ -{...}: { +{pkgs, ...}: { imports = [ # OS ../../nixos/profiles/laptop @@ -21,4 +21,28 @@ # [ ] backlight is always 33% when booted up # [ ] fan is *blasting* even after I installed mbpfans # [ ] audio quality isnt too great (compared to macOS, or i might have wooden ears) + + services.minecraft-server = { + enable = true; + eula = true; + openFirewall = true; + package = pkgs.papermc; + jvmOpts = "-Xms2G -Xmx2G -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true"; + + declarative = true; + serverProperties = { + motd = "NixOS Minecraft server!"; + white-list = true; + + difficulty = 3; + gamemode = 0; + max-players = 5; + }; + whitelist = { + "Guanran928" = "86dbb6c5-8d8b-4c45-b8eb-b3fdf03bfb27"; + "i_love_ravens" = "2788dd4b-b010-4a2f-9b5c-aad0c0e0cba5"; + }; + }; + + services.tailscale.enable = true; }