Last active
May 11, 2023 08:01
-
-
Save cyber-murmel/692ac72a807848ffb963ac047ef9ed57 to your computer and use it in GitHub Desktop.
Dedicated Satisfactory 5 Server on NixOS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{config, pkgs, lib, ...}: { | |
users.users.satisfactory = { | |
home = "/var/lib/satisfactory"; | |
createHome = true; | |
}; | |
nixpkgs.config.allowUnfree = true; | |
systemd.services.satisfactory = { | |
wantedBy = [ "multi-user.target" ]; | |
preStart = '' | |
${pkgs.steamcmd}/bin/steamcmd \ | |
+login anonymous \ | |
+force_install_dir /var/lib/satisfactory/SatisfactoryDedicatedServer \ | |
+app_update 1690800 validate \ | |
+quit | |
''; | |
script = '' | |
${pkgs.glibc}/lib/ld-linux-x86-64.so.2 /var/lib/satisfactory/SatisfactoryDedicatedServer/Engine/Binaries/Linux/UE4Server-Linux-Shipping FactoryGame | |
''; | |
serviceConfig = { | |
Nice = "-5"; | |
Restart = "always"; | |
User = "satisfactory"; | |
WorkingDirectory = "/var/lib/satisfactory"; | |
}; | |
environment = { | |
LD_LIBRARY_PATH="SatisfactoryDedicatedServer/linux64:SatisfactoryDedicatedServer/Engine/Binaries/Linux:SatisfactoryDedicatedServer/Engine/Binaries/ThirdParty/PhysX3/Linux/x86_64-unknown-linux-gnu/"; | |
}; | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey, thanks for posting this. I have updated it a bit:
https://github.com/matejc/helper_scripts/blob/master/nixes/satisfactory.nix