Move more data from HDD to NAS

This commit is contained in:
Artemis Tosini 2021-01-15 19:27:51 +00:00
parent a93ab349f7
commit 97546218f6
Signed by: artemist
GPG key ID: ADFFE553DCBB831E
5 changed files with 62 additions and 25 deletions

View file

@ -29,11 +29,8 @@
environment.shellAliases.cp = "cp --reflink=auto --sparse=always";
services.avahi = {
enable = true;
nssmdns = true;
publish.enable = true;
};
services.resolved.extraConfig = "MulticastDNS=true";
networking.firewall.enable = false;

@ -1 +1 @@
Subproject commit f8df70e380f267b3a118677bbc0d404b510222cb
Subproject commit dfdb834a29b0d481c5f94dd7d0c3e2e3a393b3ab

View file

@ -5,7 +5,8 @@
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
[
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "nvme" "usbhid" "usb_storage" ];
@ -14,25 +15,27 @@
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/de73bbb6-e56a-4aa0-8a48-c18c9d87a2b9";
{
device = "/dev/disk/by-uuid/de73bbb6-e56a-4aa0-8a48-c18c9d87a2b9";
fsType = "btrfs";
options = [ "subvol=root" ];
};
fileSystems."/home" =
{ device = "/dev/disk/by-uuid/de73bbb6-e56a-4aa0-8a48-c18c9d87a2b9";
{
device = "/dev/disk/by-uuid/de73bbb6-e56a-4aa0-8a48-c18c9d87a2b9";
fsType = "btrfs";
options = [ "subvol=home" ];
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/DB30-D60A";
{
device = "/dev/disk/by-uuid/DB30-D60A";
fsType = "vfat";
};
swapDevices =
[ { device = "/dev/disk/by-uuid/33353309-c592-40ba-8a72-f629c0776a82"; }
];
[{ device = "/dev/disk/by-uuid/33353309-c592-40ba-8a72-f629c0776a82"; }];
powerManagement.cpuFreqGovernor = lib.mkDefault "ondemand";
}

View file

@ -1,5 +1,8 @@
{ config, pkgs, ... }:
let
cifs_opts = [ "x-systemd.automount" "noauto" "x-systemd.idle-timeout=60" "x-systemd.device-timeout=5s" "x-systemd.mount-timeout=5s" "uid=${builtins.toString config.users.users.artemis.uid}" "gid=100" ];
luna_opts = cifs_opts ++ [ "credentials=/var/private/luna_creds" ];
in
{
imports = [ ../../externals/systemd-boot-secure ];
boot = {
@ -33,4 +36,7 @@
};
};
};
fileSystems."/media/luna/media".options = luna_opts;
fileSystems."/media/luna/private".options = luna_opts;
}

View file

@ -9,7 +9,7 @@
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "sd_mod" ];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ "dm-snapshot" ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
@ -28,23 +28,17 @@
options = [ "subvol=nix" ];
};
fileSystems."/home" =
{
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
fsType = "btrfs";
options = [ "subvol=home" ];
};
fileSystems."/boot" =
{
device = "/dev/disk/by-uuid/1AC2-9317";
fsType = "vfat";
};
fileSystems."/media/archive" =
fileSystems."/home" =
{
device = "/dev/disk/by-uuid/ba796824-5165-4a95-87c2-1fb49a449138";
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
fsType = "btrfs";
options = [ "subvol=home" ];
};
fileSystems."/media/data" =
@ -53,9 +47,46 @@
fsType = "btrfs";
};
boot.initrd.luks.devices."alicorn".device = "/dev/disk/by-uuid/3de20c8e-2c31-491a-a8cc-fea4762e8601";
boot.initrd.luks.devices."glimmer".device = "/dev/disk/by-uuid/43220fc3-2f33-4915-9365-59eb27b21719";
fileSystems."/var/lib/lxd/shmounts" =
{
device = "tmpfs";
fsType = "tmpfs";
};
fileSystems."/var/lib/lxd/devlxd" =
{
device = "tmpfs";
fsType = "tmpfs";
};
fileSystems."/var/lib/lxd/storage-pools/default" =
{
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
fsType = "btrfs";
options = [ "subvol=root/var/lib/lxd/storage-pools/default" ];
};
fileSystems."/var/lib/docker/btrfs" =
{
device = "/var/lib/lxd/storage-pools/default/root/var/lib/docker/btrfs";
fsType = "none";
options = [ "bind" ];
};
fileSystems."/media/luna/media" =
{
device = "//10.69.0.69/media";
fsType = "cifs";
};
fileSystems."/media/luna/private" =
{
device = "//10.69.0.69/private";
fsType = "cifs";
};
swapDevices =
[{ device = "/dev/disk/by-uuid/b134fecf-719f-45af-b317-001e413f06c4"; }];