refactor(nix): Use disk labels instead of disk UUIDs

Makes configuration portable between VM instances.
This commit is contained in:
Vincent Ambo 2018-01-02 12:08:35 +01:00
parent a9401f94db
commit f9641cc1ed
2 changed files with 6 additions and 6 deletions

View file

@ -7,6 +7,12 @@
boot.loader.grub.version = 2;
boot.loader.grub.device = "/dev/sda";
# Configure root disk
fileSystems."/" = {
device = "/dev/disk/by-label/nixos";
fsType = "ext4";
};
time.timeZone = "Europe/Oslo";
environment.systemPackages = with pkgs; [

View file

@ -2,12 +2,6 @@
sto-tazserve-1 = { pkgs, config, ... }: {
deployment.targetHost = "46.21.106.241";
# Configure root disk
fileSystems."/" = {
device = "/dev/disk/by-uuid/edb2a58c-561b-4597-9d88-9886cdfb1eac";
fsType = "ext4";
};
# Configure network
networking.hostName = "sto-tazserve-1";
networking.interfaces.ens32.ip4 = [