configures backrest

This commit is contained in:
Dennis 2026-02-20 10:08:51 +01:00
parent 623e2372a0
commit 5ff17e3a90
2 changed files with 34 additions and 0 deletions

View file

@ -18,6 +18,7 @@
../../modules/actual-server
../../modules/immich
../../modules/cockpit
../../modules/backrest
];
# General

View file

@ -0,0 +1,33 @@
{
pkgs,
config,
lib,
...
}:
{
environment.systemPackages = lib.mkAfter (
with pkgs;
[
backrest
]
);
systemd.user.services.backrest = {
Unit = {
Description = "Restic GUI";
};
Service = {
Environment = [
"BACKREST_PORT=127.0.0.1:9004"
"BACKREST_RESTIC_COMMAND=${pkgs.restic}/bin/restic"
"BACKREST_CONFIG=${config.home.homeDirectory}/.backrest/config"
"BACKREST_DATA=${config.home.homeDirectory}/.backrest/data"
];
ExecStart = "${pkgs.backrest}/bin/backrest";
Restart = "on-failure";
RestartSec = "5s";
wantedBy = [ "multi-user.target" ];
};
};
}