Compare commits

..

1 Commits

Author SHA1 Message Date
104da32e4b feat(nixos): add pikachu homepage guest 2026-09-15 17:41:15 -04:00
4 changed files with 8 additions and 37 deletions

View File

@@ -50,12 +50,6 @@ in
description = "Public IP address advertised by the Palworld server.";
};
autoStart = lib.mkOption {
type = lib.types.bool;
default = true;
description = "Start the Palworld server after the guest reaches network readiness.";
};
passwordSecret = lib.mkOption {
type = lib.types.str;
default = "services/game-servers/password";
@@ -88,7 +82,7 @@ in
guests.palworld = {
interior.modules.services.games.palworld = {
enable = true;
inherit (cfg) serverName port publicIP autoStart;
inherit (cfg) serverName port publicIP;
inherit steamDir installDir stateDir;
passwordFile = "/run/secrets/${cfg.passwordSecret}";
adminPasswordFile = "/run/secrets/${cfg.adminPasswordSecret}";

View File

@@ -94,7 +94,6 @@
installPath = "/pikachu/data/servers/palworld/tracion";
statePath = "/pikachu/media/games/servers/palworld/tracion";
serverName = "Tracion";
autoStart = false;
adminPasswordSecret = "services/game-servers/admin/password";
publicIP = config.guests.palworld.address;
reverseProxy = {

View File

@@ -56,12 +56,6 @@
description = "Advertise the server in Palworld's public lobby.";
};
autoStart = lib.mkOption {
type = lib.types.bool;
default = true;
description = "Start the Palworld server after the guest reaches network readiness.";
};
rcon = {
enable = lib.mkEnableOption "Palworld RCON" // {
default = true;
@@ -132,7 +126,6 @@
inherit (service) steamDir installDir stateDir;
serviceName = "palworld-${lib.toLower service.serverName}";
appId = 2394010;
inherit (service) autoStart;
executable = "${startScript}";
arguments =
[

View File

@@ -65,12 +65,6 @@
default = [ ];
description = "TCP ports opened for the game service.";
};
autoStart = lib.mkOption {
type = lib.types.bool;
default = true;
description = "Start the game service after the guest reaches network readiness.";
};
};
config = lib.mkMerge [
@@ -148,33 +142,24 @@
};
};
"${service.serviceName}-autostart" = {
description = "Queue ${service.serviceName} game server startup";
after = [ "network-online.target" ];
wants = [ "network-online.target" ];
wantedBy = lib.mkIf service.autoStart [ "multi-user.target" ];
serviceConfig = {
Type = "oneshot";
ExecStart = "${pkgs.systemd}/bin/systemctl --no-block start ${service.serviceName}.service";
};
};
${service.serviceName} = {
description = "${service.serviceName} game server";
after = [
"multi-user.target"
"network-online.target"
"steamcmd-${service.serviceName}-update.service"
];
wants = [
"network-online.target"
"steamcmd-${service.serviceName}-update.service"
];
wants = [ "network-online.target" ];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
Type = "simple";
User = user;
Group = group;
WorkingDirectory = "-${service.installDir}";
ExecStartPre = "+${prepareScript}";
ExecStartPre = [
"+${prepareScript}"
updateScript
];
ExecStart = startScript;
Restart = "on-failure";
TimeoutStartSec = "15min";