Add host backup-4
This commit is contained in:
parent
cc38f3aa65
commit
548004b1a1
42
hosts/backup-4/configuration.nix
Normal file
42
hosts/backup-4/configuration.nix
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports =
|
||||||
|
[
|
||||||
|
./hardware-configuration.nix
|
||||||
|
../../configuration/common
|
||||||
|
../../configuration/proxmox-vm
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.loader.grub.enable = true;
|
||||||
|
boot.loader.grub.version = 2;
|
||||||
|
boot.loader.grub.device = "/dev/vda";
|
||||||
|
|
||||||
|
networking.hostName = "backup-4";
|
||||||
|
|
||||||
|
networking.useDHCP = false;
|
||||||
|
networking.interfaces.ens18.ipv6.addresses = [ { address = "2001:638:904:ffcb::c"; prefixLength = 64; } ];
|
||||||
|
networking.defaultGateway6 = { address = "2001:638:904:ffcb::1"; interface = "ens18"; };
|
||||||
|
networking.nameservers = [ "2001:638:904:ffcc::3" "2001:638:904:ffcc::4" "141.24.40.3" "141.24.40.4" ];
|
||||||
|
|
||||||
|
services.rsnapshot = {
|
||||||
|
enable = true;
|
||||||
|
extraConfig = ''
|
||||||
|
snapshot_root /mnt/backup-4/
|
||||||
|
retain daily 14
|
||||||
|
ssh_args -o BatchMode=yes -o IdentityFile=/var/src/secrets/rsnapshot/id_rsa
|
||||||
|
backup backup-replication@clerie-backup.net.clerie.de:/clerie-backup-replication/ clerie-backup/
|
||||||
|
'';
|
||||||
|
cronIntervals = {
|
||||||
|
daily = "15 6 * * * ";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
clerie.monitoring = {
|
||||||
|
enable = true;
|
||||||
|
id = "205";
|
||||||
|
pubkey = "CLEF5hLdjwPqfU1oaM16fusJ705iNzUBxYsb4/YuGw4=";
|
||||||
|
};
|
||||||
|
|
||||||
|
system.stateVersion = "21.03";
|
||||||
|
}
|
28
hosts/backup-4/hardware-configuration.nix
Normal file
28
hosts/backup-4/hardware-configuration.nix
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
|
# and may be overwritten by future invocations. Please make changes
|
||||||
|
# to /etc/nixos/configuration.nix instead.
|
||||||
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports =
|
||||||
|
[ (modulesPath + "/profiles/qemu-guest.nix")
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" "virtio_blk" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
fileSystems."/" =
|
||||||
|
{ device = "/dev/disk/by-uuid/eb9bcb35-4f34-4cd6-b1b3-3a86de40571b";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/mnt/backup-4" =
|
||||||
|
{ device = "/dev/disk/by-uuid/f4d2a27d-664b-45f7-abc2-adf6691ad363";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [ ];
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user