os/hosts/chocolatebar/factorio/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

48 lines
972 B
Nix
Raw Permalink Normal View History

2023-01-28 21:27:52 +00:00
{
config,
pkgs,
lib,
self,
...
}:
with lib; let
2022-10-17 13:56:48 +00:00
psCfg = config.pub-solar;
xdg = config.home-manager.users."${psCfg.user.name}".xdg;
far-reach = pkgs.stdenv.mkDerivation rec {
pname = "factorio-far-reach";
version = "1.1.2";
src = ./far-reach_1.1.2.zip;
2023-01-28 21:27:52 +00:00
phases = ["installPhase"];
deps = [];
2022-10-17 13:56:48 +00:00
installPhase = ''
mkdir -p $out
cp $src far-reach_1.1.2.zip
'';
};
2023-01-28 21:27:52 +00:00
in {
2022-10-17 13:56:48 +00:00
config = {
services.factorio = {
enable = true;
port = 34197; # The default, but make it explicit
lan = true;
2022-11-28 10:39:21 +00:00
game-password = "pls-dont-grief";
2022-10-17 13:56:48 +00:00
admins = [
"doubtwriter"
2022-11-09 17:23:12 +00:00
"kattykat"
2022-10-17 13:56:48 +00:00
];
openFirewall = true;
autosave-interval = 3;
2022-11-09 17:23:12 +00:00
game-name = "Babes plays v2";
2022-10-17 13:56:48 +00:00
requireUserVerification = false;
2022-11-28 10:39:21 +00:00
bind = "::";
2022-10-17 13:56:48 +00:00
mods = [
far-reach
];
};
2022-11-28 10:39:21 +00:00
2023-01-28 21:27:52 +00:00
networking.firewall.allowedUDPPorts = [34197];
networking.firewall.allowedTCPPorts = [34197];
2022-10-17 13:56:48 +00:00
};
}