stockholm/lass/1systems/blue/config.nix

44 lines
1.1 KiB
Nix
Raw Normal View History

2018-05-16 15:26:19 +00:00
with import <stockholm/lib>;
{ config, lib, pkgs, ... }:
{
imports = [
<stockholm/lass>
<stockholm/lass/2configs>
<stockholm/lass/2configs/retiolum.nix>
2018-05-20 08:20:10 +00:00
<stockholm/lass/2configs/exim-retiolum.nix>
<stockholm/lass/2configs/blue.nix>
2019-03-23 15:06:39 +00:00
<stockholm/lass/2configs/syncthing.nix>
2019-04-17 18:00:06 +00:00
<stockholm/lass/2configs/sync/decsync.nix>
<stockholm/lass/2configs/sync/weechat.nix>
2018-05-16 15:26:19 +00:00
];
krebs.build.host = config.krebs.hosts.blue;
2018-05-20 08:20:10 +00:00
networking.nameservers = [ "1.1.1.1" ];
2019-04-07 16:55:47 +00:00
services.restic.backups = genAttrs [
2018-05-20 08:20:10 +00:00
"daedalus"
"icarus"
"littleT"
"prism"
"shodan"
"skynet"
] (dest: {
2019-04-07 16:55:47 +00:00
initialize = true;
extraOptions = [
"sftp.command='ssh backup@${dest}.r -i ${config.krebs.build.host.ssh.privkey.path} -s sftp'"
2018-05-20 08:20:10 +00:00
];
2019-04-07 16:55:47 +00:00
repository = "sftp:backup@${dest}.r:/backups/blue";
2018-05-20 08:20:10 +00:00
passwordFile = (toString <secrets>) + "/restic/${dest}";
2019-04-07 16:55:47 +00:00
timerConfig = { OnCalendar = "00:05"; RandomizedDelaySec = "5h"; };
paths = [
"/home/"
"/var/lib"
2018-05-20 08:20:10 +00:00
];
});
2019-04-07 16:55:47 +00:00
2018-05-20 08:20:10 +00:00
time.timeZone = "Europe/Berlin";
users.users.mainUser.openssh.authorizedKeys.keys = [ config.krebs.users.lass-android.pubkey ];
2018-05-16 15:26:19 +00:00
}