From 545d9ba7d909ef98ff7f169da83591f5c2d64250 Mon Sep 17 00:00:00 2001 From: notohh Date: Tue, 9 Jan 2024 22:56:48 -0500 Subject: [PATCH] sora: add terraria --- hosts/sora/services/default.nix | 1 + hosts/sora/services/terraria.nix | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 hosts/sora/services/terraria.nix diff --git a/hosts/sora/services/default.nix b/hosts/sora/services/default.nix index 36d47c5..0c72596 100644 --- a/hosts/sora/services/default.nix +++ b/hosts/sora/services/default.nix @@ -7,6 +7,7 @@ ./attic.nix ./tailscale.nix ./croc.nix + ./terraria.nix # ./factorio.nix # ./minecraft.nix # ./foundryvtt.nix diff --git a/hosts/sora/services/terraria.nix b/hosts/sora/services/terraria.nix new file mode 100644 index 0000000..ba0e2db --- /dev/null +++ b/hosts/sora/services/terraria.nix @@ -0,0 +1,24 @@ +{...}: { + networking.firewall.allowedTCPPorts = [7777]; + virtualisation.oci-containers.containers.terraria = { + image = "jacobsmile/tmodloader1.4:v2023.11.3.3"; + ports = ["7777:7777"]; + volumes = ["/var/lib/terraria/tmodloader:/data"]; + environment = { + TMOD_MOTD = "forsen"; + TMOD_PASS = "forsen"; + TMOD_AUTOSAVE_INTERVAL = "10"; + TMOD_SHUTDOWN_MESSAGE = "Server is shutting down NOW!"; + TMOD_AUTODOWNLOAD = "2824688072,2824688266,2669644269,2563309347,2619954303,2687866031,2563851005,2908170107"; + TMOD_ENABLEDMODS = "2824688072,2824688266,2669644269,2563309347,2619954303,2687866031,2563851005,2908170107"; + TMOD_MAXPLAYERS = "10"; + TMOD_WORLDNAME = "forsenv2"; + TMOD_WORLDSIZE = "3"; + TMOD_DIFFICULTY = "2"; + TMOD_NPCSTREAM = "60"; + TMOD_WORLDSEED = "random"; + TMOD_LANGUAGE = "en-US"; + TMOD_UPNP = "1"; + }; + }; +}