restic: make global module
This commit is contained in:
parent
12a7ea01dc
commit
bc2cb88ea4
2 changed files with 20 additions and 20 deletions
20
modules/nixos/services/restic.nix
Normal file
20
modules/nixos/services/restic.nix
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
# make wrapper to run restic rootless
|
||||
users = {
|
||||
users.restic = {
|
||||
group = "restic";
|
||||
isSystemUser = true;
|
||||
};
|
||||
groups.restic = {};
|
||||
};
|
||||
|
||||
security.wrappers.restic = {
|
||||
source = lib.getExe pkgs.restic;
|
||||
owner = "restic";
|
||||
group = "restic";
|
||||
permissions = "500";
|
||||
capabilities = "cap_dac_read_search+ep";
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue