feat(servers): reset 7days map and add auto backups
All checks were successful
Discord / discord commits (push) Successful in 38s

This commit is contained in:
matt1432 2024-07-13 22:12:35 -04:00
parent 031a36acdd
commit d13e984368
2 changed files with 34 additions and 22 deletions

View file

@ -2,12 +2,15 @@
gamePath = "/var/lib/steam-servers/7-days-to-die";
relativeConfig = "serverconfig-7days.xml";
in {
systemd.extraConfig = "DefaultLimitNOFILE=10240";
services.borgbackup.configs."seven-days" = {
paths = ["/var/lib/steam-servers/7-days-to-die"];
startAt = "02/3:00";
};
# TODO: make backups
systemd = {
extraConfig = "DefaultLimitNOFILE=10240";
# https://github.com/Krutonium/NewNix/blob/455aafc4caf553248ca228f844f021cecf494dc2/services/sevendaystodie.nix#L6
systemd.services."7-days-to-die" = {
services."7-days-to-die" = {
wantedBy = ["multi-user.target"];
serviceConfig.User = "matt";
@ -31,4 +34,5 @@ in {
steam-run ./startserver.sh -configfile=${relativeConfig}
'';
};
};
}

View file

@ -9,12 +9,20 @@
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPijoxuSwH9IrS4poewzHHwe64UoX4QY7Qix5VhEdqKR root@servivi"
];
}
{
name = "mc";
authorizedKeys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPijoxuSwH9IrS4poewzHHwe64UoX4QY7Qix5VhEdqKR root@servivi"
];
}
{
name = "seven-days";
authorizedKeys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPijoxuSwH9IrS4poewzHHwe64UoX4QY7Qix5VhEdqKR root@servivi"
];
}
];
};
}