Remove obsolete stuff
This commit is contained in:
parent
60f2d8f038
commit
da182e4945
|
@ -191,7 +191,7 @@
|
|||
./hardware/intel-nuc.nix
|
||||
./modules/local-build-service.nix
|
||||
./modules/nginx-reverse-proxy.nix
|
||||
./modules/binary-cache.nix
|
||||
#./modules/binary-cache.nix
|
||||
./modules/ccqcraft-backups.nix
|
||||
./modules/restic.nix
|
||||
];
|
||||
|
|
|
@ -42,22 +42,6 @@
|
|||
sops.defaultSopsFile = ../secrets/hosts/elysia-clarki/secrets.yaml;
|
||||
sops.age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
|
||||
|
||||
services.ddclient = {
|
||||
enable = true;
|
||||
protocol = "dyndns2";
|
||||
server = "dynv6.com";
|
||||
username = "none";
|
||||
# Fixup using secret scheme
|
||||
passwordFile = "/root/ddclient-password";
|
||||
zone = "home.dyn.tammena.rocks";
|
||||
domains = [
|
||||
"bak.home.dyn.tammena.rocks"
|
||||
"cache.home.dyn.tammena.rocks"
|
||||
"elysia-clarki.home.dyn.tammena.rocks"
|
||||
];
|
||||
ipv6 = true;
|
||||
};
|
||||
|
||||
# This value determines the NixOS release from which the default
|
||||
# settings for stateful data, like file locations and database versions
|
||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||
|
|
|
@ -1,65 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
let
|
||||
resticCmd = "${pkgs.restic}/bin/restic";
|
||||
repository = "rest:http://elysia-clarki.home.dyn.tammena.rocks:8000/malte";
|
||||
passCmd = "${pkgs.pass}/bin/pass Server/ResticServer/malte";
|
||||
backupPaths = [
|
||||
"/home/malte/Documents"
|
||||
"/home/malte/Lieder"
|
||||
"/home/malte/Pictures"
|
||||
"/home/malte/Tasks"
|
||||
"/home/malte/Uni"
|
||||
"/home/malte/helden"
|
||||
"/home/malte/ledger"
|
||||
"/home/malte/timewarrior"
|
||||
"/home/malte/vimwiki"
|
||||
];
|
||||
pruneOpts = [
|
||||
"--keep-hourly 5"
|
||||
"--keep-daily 5"
|
||||
"--keep-weekly 5"
|
||||
"--keep-monthly 5"
|
||||
"--keep-yearly 5"
|
||||
];
|
||||
|
||||
in {
|
||||
home.packages = [ pkgs.restic ];
|
||||
|
||||
home.sessionVariables = {
|
||||
RESTIC_REPOSITORY = repository;
|
||||
RESTIC_PASSWORD_COMMAND = passCmd;
|
||||
};
|
||||
|
||||
systemd.user.services.restic-backups-to-elysia-clarki = {
|
||||
Unit = {
|
||||
Description = "Backup to elysia-clarki using restic";
|
||||
After = [ "network.target" "dev-yubikey.device" ];
|
||||
Requisite = "dev-yubikey.device";
|
||||
};
|
||||
Service = {
|
||||
Type = "oneshot";
|
||||
ExecStart = [
|
||||
"${resticCmd} backup --cache-dir=%C/restic-backups-to-elysia-clarki ${
|
||||
toString backupPaths
|
||||
}"
|
||||
"${resticCmd} forget --prune ${toString pruneOpts}"
|
||||
];
|
||||
RuntimeDirectory = "restic-backups-to-elysia-clarki";
|
||||
CacheDirectory = "restic-backups-to-elysia-clarki";
|
||||
CacheDirectoryMode = "0700";
|
||||
Environment = [
|
||||
"RESTIC_REPOSITORY=${repository}"
|
||||
''RESTIC_PASSWORD_COMMAND="${passCmd}"''
|
||||
"PASSWORD_STORE_DIR=/home/malte/.local/share/password-store"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.timers.restic-backups-to-elysia-clarki = {
|
||||
Unit = { Description = "Run restic backups every hour"; };
|
||||
Install = { WantedBy = [ "timers.target" ]; };
|
||||
Timer = { OnCalendar = "hourly"; };
|
||||
};
|
||||
|
||||
}
|
Loading…
Reference in a new issue