diff options
author | Sofi <sofi+git@mailbox.org> | 2022-08-25 19:21:33 +0200 |
---|---|---|
committer | Winter <winter@winter.cafe> | 2022-08-26 23:22:52 -0400 |
commit | 07c76c980cc8888f98b670bfce1e21e1fda765dc (patch) | |
tree | e7c93d41bbe4edfad1cdfc779322654ba324aeee /nixos/tests/minecraft-server.nix | |
parent | d7cef0d40f8b36e300e0eb74e2eacc3154d23757 (diff) |
nixos/minecraft-server: optimize world generation inside test
Due to how complex minecraft world generation has gotten in recent years, it now can take several minutes to complete the first generation of a world seed, even on relatively new and powerful hardware. We are testing if a minecraft server can run inside of a nix enviroment, and not so much about stress testing the CI. Test running before this change: > (finished: waiting for TCP port 43000, in 118.49 seconds) Test running with this change: > (finished: waiting for TCP port 43000, in 27.88 seconds) Choice of using `level-type` and `generate-structures` was made as they support almost every version of minecraft. These two also make it extremely clear what it does, compared to the more complex `generator-settings` and all its toggles.
Diffstat (limited to 'nixos/tests/minecraft-server.nix')
-rw-r--r-- | nixos/tests/minecraft-server.nix | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/nixos/tests/minecraft-server.nix b/nixos/tests/minecraft-server.nix index a51b36ff53084..6e733bb96c1c5 100644 --- a/nixos/tests/minecraft-server.nix +++ b/nixos/tests/minecraft-server.nix @@ -18,6 +18,8 @@ in import ./make-test-python.nix ({ pkgs, ... }: { serverProperties = { enable-rcon = true; level-seed = seed; + level-type = "flat"; + generate-structures = false; online-mode = false; "rcon.password" = rcon-pass; "rcon.port" = rcon-port; |