feat(servers): attempt to make a 7 Days to Die server
All checks were successful
Discord / discord commits (push) Successful in 1m14s

This commit is contained in:
matt1432 2024-06-28 17:43:43 -04:00
parent 2789cbed33
commit df6fc2d165
9 changed files with 484 additions and 2 deletions

View file

@ -24,7 +24,7 @@
boot.tmp.useTmpfs = true;
systemd.services.nix-daemon = {
environment.TMPDIR = "/run/nix-cache";
environment.TMPDIR = "/home/nix-cache";
preStart = ''
mkdir -p ${config.systemd.services.nix-daemon.environment.TMPDIR}
'';

View file

@ -12,6 +12,7 @@ in {
./modules/binary-cache.nix
./modules/minecraft.nix
./modules/nfs.nix
./modules/steam-servers
];
vars = {

View file

@ -0,0 +1,19 @@
{
pkgs,
steam-servers,
...
}: {
imports = [steam-servers.nixosModules.default];
services.steam-servers."7-days-to-die" = {
mainServ = {
enable = true;
package = pkgs.callPackage ./seven-days.nix {};
config = {
ServerName = "bruh moment";
ServerPort = 26900;
};
};
};
}

View file

@ -0,0 +1,119 @@
{
"appId": 294420,
"depotId": 294422,
"name": "7-days-to-die-server",
"branches": {
"public": "12696583",
"alpha10.4": "480993",
"alpha11.6": "658147",
"alpha12.5": "745252",
"alpha13.8": "963565",
"alpha14.7": "1189196",
"alpha15.2": "1642899",
"alpha16.4": "2222523",
"alpha17.4": "3848769",
"alpha18.4": "4714812",
"alpha19.6": "7108526",
"alpha20.4": "8604296",
"alpha20.5": "8673178",
"alpha20.6": "9269710",
"alpha20.7": "10740013",
"alpha21.0": "11589588",
"alpha21.1": "11888696",
"alpha21.2": "12696583",
"alpha9.3": "385244",
"latest_experimental": "12696583"
},
"builds": {
"385244": {
"hash": "sha256-Y3H/mcUGgiuctfp27l4qJM+RtzFqB/nRcQ2v58Y/lQs=\n",
"manifestId": "771574079178892216",
"version": "A9.3"
},
"480993": {
"hash": "sha256-rHIq7ZdAyIlK/99vPpipHn8rk2dWoxOPySDwgPtqOFc=\n",
"manifestId": "869964754451803329",
"version": "A10.4"
},
"658147": {
"hash": "sha256-FtGdi7IfCcORe5bgpNk1ldxPoskrLTuVtp/hPpiam54=\n",
"manifestId": "6322866582767616058",
"version": "A11.6"
},
"745252": {
"hash": "sha256-hDeHIoqd9vSHOtMLdZMEFXsa1m08MDKtj/IOTgY4nLw=\n",
"manifestId": "4986361730962654647",
"version": "A12.5"
},
"963565": {
"hash": "sha256-i+lqXyHj1Rh7g1jvQwHjACLdmvwHbqsDRAViCeGxwPw=\n",
"manifestId": "7779347169826947318",
"version": "A13.8"
},
"1189196": {
"hash": "sha256-eb5jGQ3ZXISaR1XLjRfWU0WnPsCAlICpLswYARKGPUg=\n",
"manifestId": "6623540452959702677",
"version": "A14.7"
},
"1642899": {
"hash": "sha256-PUp6CAIb5ifckoQATk0HiSI+38tG7s4++ZdGP9pGTYw=\n",
"manifestId": "2556346443150106043",
"version": "A15.2"
},
"2222523": {
"hash": "sha256-wfEN9h30pOZ4I40Mknhj4DYLCobxClfAAVwcQAh/xHA=\n",
"manifestId": "2507660789418272148",
"version": "A16.4"
},
"3848769": {
"hash": "sha256-5+vPyQa83lQipXAiVjUax5ZjRgZ2bV8+4JPeYAptURo=\n",
"manifestId": "779748564640465657",
"version": "A17.4"
},
"4714812": {
"hash": "sha256-/NSpYdo6Jbg8sAa0Tm2CjjtI29mw+UpPHJ6UHlvrnuk=\n",
"manifestId": "712346436815285918",
"version": "A18.4"
},
"7108526": {
"hash": "sha256-GaDPdMfRPm/b/w+TCCliJLKh8qXV1oOsF8nn/vdjkCE=\n",
"manifestId": "8368733426395777657",
"version": "A19.6"
},
"8604296": {
"hash": "sha256-CdCqILAUF7Pm4fsqh7GGgnUyLF313EpbqY876cr0XJY=\n",
"manifestId": "7450223064053935691",
"version": "A20.4"
},
"8673178": {
"hash": "sha256-+NFOV+j2rEAROjuRmg4EBqpYmCk+k69lL4uRxuSYH8g=\n",
"manifestId": "8340716617723021748",
"version": "A20.5"
},
"9269710": {
"hash": "sha256-DGFUY9yPuJw7B8MULLVqnHOUWCfn49rXkkONzEg44zQ=\n",
"manifestId": "5719205947052582383",
"version": "A20.6"
},
"10740013": {
"hash": "sha256-zcORacHWkT8GvOn6XSEYbPMEiHaBFi7x7e6jwWxmWjg=\n",
"manifestId": "4716968955855516282",
"version": "A20.7"
},
"11589588": {
"hash": "sha256-V23otEJmR73X2OtX78WOfArk4T2Qt/aUhFGCTBjXYII=\n",
"manifestId": "377642321521054757",
"version": "A21.0"
},
"11888696": {
"hash": "sha256-gl9t5wKzqcEHwxmP1EJEJ7JVod7nCq0CKxK0fzQBApI=\n",
"manifestId": "4485042179748822610",
"version": "A21.1"
},
"12696583": {
"hash": "sha256-bxV/B8vEiuEpn1po2De3H6iVSLbhqe5dCAIBhnQSNsQ=\n",
"manifestId": "1977371197884973023",
"version": "A21.2"
}
}
}

View file

@ -0,0 +1,26 @@
{
lib,
mkSteamPackage,
gcc-unwrapped,
zlib,
}:
mkSteamPackage {
lockFile = ./lock.json;
buildInputs = [
gcc-unwrapped
zlib
];
meta = with lib; {
description = "7 Days to Die dedicated server";
homepage = "https://steamdb.info/app/294420/";
changelog = "https://store.steampowered.com/news/app/251570?updates=true";
sourceProvenance = with sourceTypes; [
binaryNativeCode # Steam games are always going to contain some native binary component.
binaryBytecode # e.g. Unity games using C#
];
license = licenses.unfree;
platforms = ["x86_64-linux"];
};
}

View file

@ -155,6 +155,28 @@
"type": "github"
}
},
"devshell": {
"inputs": {
"flake-utils": "flake-utils_4",
"nixpkgs": [
"steam-servers",
"nixpkgs"
]
},
"locked": {
"lastModified": 1705332421,
"narHash": "sha256-USpGLPme1IuqG78JNqSaRabilwkCyHmVWY0M9vYyqEA=",
"owner": "numtide",
"repo": "devshell",
"rev": "83cb93d6d063ad290beee669f4badf9914cc16ec",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "devshell",
"type": "github"
}
},
"dracula-plymouth-src": {
"flake": false,
"locked": {
@ -267,6 +289,22 @@
"type": "github"
}
},
"flake-compat_5": {
"flake": false,
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": {
"inputs": {
"nixpkgs-lib": [
@ -288,6 +326,27 @@
"type": "github"
}
},
"flake-parts_10": {
"inputs": {
"nixpkgs-lib": [
"steam-servers",
"nixpkgs"
]
},
"locked": {
"lastModified": 1706830856,
"narHash": "sha256-a0NYyp+h9hlb7ddVz4LUn1vT/PLwqfrWYcHMvFB1xYg=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "b253292d9c0a5ead9bc98c4e9a26c6312e27d69f",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_2": {
"inputs": {
"nixpkgs-lib": [
@ -463,6 +522,21 @@
"type": "github"
}
},
"flake-root_2": {
"locked": {
"lastModified": 1692742795,
"narHash": "sha256-f+Y0YhVCIJ06LemO+3Xx00lIcqQxSKJHXT/yk1RTKxw=",
"owner": "srid",
"repo": "flake-root",
"rev": "d9a70d9c7a5fd7f3258ccf48da9335e9b47c3937",
"type": "github"
},
"original": {
"owner": "srid",
"repo": "flake-root",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems_3"
@ -517,6 +591,42 @@
"type": "github"
}
},
"flake-utils_4": {
"inputs": {
"systems": "systems_7"
},
"locked": {
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_5": {
"inputs": {
"systems": "systems_8"
},
"locked": {
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flakegen": {
"inputs": {
"systems": "systems"
@ -622,6 +732,28 @@
"type": "github"
}
},
"gitignore_3": {
"inputs": {
"nixpkgs": [
"steam-servers",
"pre-commit-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1703887061,
"narHash": "sha256-gGPa9qWNc6eCXT/+Z5/zMkyYOuRZqeFZBDbopNZQkuY=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "43e1aa1308018f37118e34d3a9cb4f5e75dc11d5",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"gpu-screen-recorder-src": {
"flake": false,
"locked": {
@ -1684,6 +1816,22 @@
"type": "github"
}
},
"nixpkgs-stable_4": {
"locked": {
"lastModified": 1704874635,
"narHash": "sha256-YWuCrtsty5vVZvu+7BchAxmcYzTMfolSPP5io8+WYCg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "3dc440faeee9e889fe2d1b4d25ad0f430d449356",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-23.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-wayland": {
"inputs": {
"flake-compat": "flake-compat_4",
@ -1946,6 +2094,31 @@
"type": "github"
}
},
"pre-commit-hooks_2": {
"inputs": {
"flake-compat": "flake-compat_5",
"flake-utils": "flake-utils_5",
"gitignore": "gitignore_3",
"nixpkgs": [
"steam-servers",
"nixpkgs"
],
"nixpkgs-stable": "nixpkgs-stable_4"
},
"locked": {
"lastModified": 1708018599,
"narHash": "sha256-M+Ng6+SePmA8g06CmUZWi1AjG2tFBX9WCXElBHEKnyM=",
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"rev": "5df5a70ad7575f6601d91f0efec95dd9bc619431",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"type": "github"
}
},
"root": {
"inputs": {
"Hyprspace": "Hyprspace",
@ -2000,6 +2173,8 @@
"secrets": "secrets",
"sioyek-theme-src": "sioyek-theme-src",
"sops-nix": "sops-nix_2",
"steam-fetcher": "steam-fetcher",
"steam-servers": "steam-servers",
"stylelint-lsp": "stylelint-lsp",
"subsync": "subsync",
"trash-d-src": "trash-d-src",
@ -2121,6 +2296,73 @@
"type": "github"
}
},
"steam-fetcher": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1714795926,
"narHash": "sha256-PkgC9jqoN6cJ8XYzTA2PlrWs7aPJkM3BGiTxNqax0cA=",
"owner": "nix-community",
"repo": "steam-fetcher",
"rev": "12f66eafb7862d91b3e30c14035f96a21941bd9c",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "steam-fetcher",
"type": "github"
}
},
"steam-fetcher_2": {
"inputs": {
"nixpkgs": [
"steam-servers",
"nixpkgs"
]
},
"locked": {
"lastModified": 1703704267,
"narHash": "sha256-X44wqMWyaMsymcrgxwlnEWDplcop54e3eopfJ/p+S3s=",
"owner": "aidalgol",
"repo": "nix-steam-fetcher",
"rev": "aa223d3d03fd60a7b9f20831a06776ca0f1b3630",
"type": "github"
},
"original": {
"owner": "aidalgol",
"repo": "nix-steam-fetcher",
"type": "github"
}
},
"steam-servers": {
"inputs": {
"devshell": "devshell",
"flake-parts": "flake-parts_10",
"flake-root": "flake-root_2",
"nixpkgs": [
"nixpkgs"
],
"pre-commit-hooks": "pre-commit-hooks_2",
"steam-fetcher": "steam-fetcher_2",
"treefmt-nix": "treefmt-nix_4"
},
"locked": {
"lastModified": 1712364428,
"narHash": "sha256-DpKCpHXIokf2G6gO6gvv3JtzhvhRI9HB3hLrGVrvSIY=",
"owner": "scottbot95",
"repo": "nix-steam-servers",
"rev": "42f01ff2d2635b4f559264e988ac8f6e803a6623",
"type": "github"
},
"original": {
"owner": "scottbot95",
"repo": "nix-steam-servers",
"type": "github"
}
},
"stylelint-lsp": {
"inputs": {
"nixpkgs": [
@ -2255,6 +2497,36 @@
}
},
"systems_7": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_8": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_9": {
"locked": {
"lastModified": 1689347949,
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
@ -2349,6 +2621,27 @@
"type": "github"
}
},
"treefmt-nix_4": {
"inputs": {
"nixpkgs": [
"steam-servers",
"nixpkgs"
]
},
"locked": {
"lastModified": 1707300477,
"narHash": "sha256-qQF0fEkHlnxHcrKIMRzOETnRBksUK048MXkX0SOmxvA=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "ac599dab59a66304eb511af07b3883114f061b9d",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "treefmt-nix",
"type": "github"
}
},
"vimplugin-easytables-src": {
"flake": false,
"locked": {
@ -2386,7 +2679,7 @@
"nixpkgs": [
"nixpkgs"
],
"systems": "systems_7"
"systems": "systems_9"
},
"locked": {
"lastModified": 1718794850,

View file

@ -307,6 +307,18 @@
repo = "sops-nix";
type = "github";
};
steam-fetcher = {
inputs.nixpkgs.follows = "nixpkgs";
owner = "nix-community";
repo = "steam-fetcher";
type = "github";
};
steam-servers = {
inputs.nixpkgs.follows = "nixpkgs";
owner = "scottbot95";
repo = "nix-steam-servers";
type = "github";
};
stylelint-lsp = {
inputs.nixpkgs.follows = "nixpkgs";
owner = "matt1432";

View file

@ -89,6 +89,16 @@ let
repo = "nixos-minecraft-servers";
};
steam-servers = mkDep {
owner = "scottbot95";
repo = "nix-steam-servers";
};
steam-fetcher = mkDep {
owner = "nix-community";
repo = "steam-fetcher";
};
nix-eval-jobs = mkDep {
owner = "nix-community";
repo = "nix-eval-jobs";

View file

@ -16,6 +16,8 @@
inputs.grim-hyprland.overlays.default
inputs.jovian.overlays.default
inputs.nixpkgs-wayland.overlays.default
inputs.steam-fetcher.overlays.default
inputs.steam-servers.overlays.default
];
};