diff options
author | Franck Cuny <franck@fcuny.net> | 2022-03-09 18:37:51 -0800 |
---|---|---|
committer | Franck Cuny <franck@fcuny.net> | 2022-03-09 18:37:51 -0800 |
commit | e6f9e7b3fa1a05b7d9179ecb83f1ded950b06659 (patch) | |
tree | c161eea39d25a193d0f6e99bed9e585b30689870 /hosts | |
parent | gitea: we need to specify the user for the DB (diff) | |
download | world-e6f9e7b3fa1a05b7d9179ecb83f1ded950b06659.tar.gz |
gitea: do a backup with restic
Diffstat (limited to 'hosts')
-rw-r--r-- | hosts/common/server/gitea.nix | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/hosts/common/server/gitea.nix b/hosts/common/server/gitea.nix index 9b9bf83..b90ef51 100644 --- a/hosts/common/server/gitea.nix +++ b/hosts/common/server/gitea.nix @@ -27,4 +27,16 @@ in { user = cfg.user; }; }; + + services.restic.backups = { + gitea = { + paths = [ cfg.Statedir ]; + repository = "/data/slow/backups/systems"; + passwordFile = config.age.secrets.restic-repo-systems.path; + timerConfig = { OnCalendar = "00:15"; }; + initialize = true; + extraBackupArgs = [ "--tag gitea" ]; + pruneOpts = [ "--keep-daily 7" "--keep-weekly 4 --keep-monthly 6" ]; + }; + }; } |