add lvm test
This commit is contained in:
		
							parent
							
								
									c29b0d1d6a
								
							
						
					
					
						commit
						a0966aad40
					
				
					 1 changed files with 70 additions and 0 deletions
				
			
		
							
								
								
									
										70
									
								
								disko/EDI/lvm.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										70
									
								
								disko/EDI/lvm.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,70 @@
 | 
			
		|||
{
 | 
			
		||||
  disko.devices = {
 | 
			
		||||
    disk = {
 | 
			
		||||
      nvme0n1 = {
 | 
			
		||||
        type = "disk";
 | 
			
		||||
        device = "/dev/disk/by-path/pci-0000:71:00.0-nvme-1";
 | 
			
		||||
        content = {
 | 
			
		||||
          type = "gpt";
 | 
			
		||||
          partitions = {
 | 
			
		||||
            ESP = {
 | 
			
		||||
              size = "512M";
 | 
			
		||||
              type = "EF00";
 | 
			
		||||
              content = {
 | 
			
		||||
                type = "filesystem";
 | 
			
		||||
                format = "vfat";
 | 
			
		||||
                mountpoint = "/boot";
 | 
			
		||||
                mountOptions = [
 | 
			
		||||
                  "defaults"
 | 
			
		||||
                ];
 | 
			
		||||
              };
 | 
			
		||||
            };
 | 
			
		||||
            luks = {
 | 
			
		||||
              size = "100%";
 | 
			
		||||
              content = {
 | 
			
		||||
                type = "luks";
 | 
			
		||||
                name = "crypted";
 | 
			
		||||
                extraOpenArgs = [];
 | 
			
		||||
                settings = {
 | 
			
		||||
                  # if you want to use the key for interactive login be sure there is no trailing newline
 | 
			
		||||
                  # for example use `echo -n "password" > /tmp/secret.key`
 | 
			
		||||
                  #keyFile = "/tmp/secret.key";
 | 
			
		||||
                  allowDiscards = true;
 | 
			
		||||
                };
 | 
			
		||||
                #additionalKeyFiles = ["/tmp/additionalSecret.key"];
 | 
			
		||||
                content = {
 | 
			
		||||
                  type = "lvm_pv";
 | 
			
		||||
                  vg = "pool";
 | 
			
		||||
                };
 | 
			
		||||
              };
 | 
			
		||||
            };
 | 
			
		||||
          };
 | 
			
		||||
        };
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
    lvm_vg = {
 | 
			
		||||
      pool = {
 | 
			
		||||
        type = "lvm_vg";
 | 
			
		||||
        lvs = {
 | 
			
		||||
          swap = {
 | 
			
		||||
            size = "4G";
 | 
			
		||||
            content = {
 | 
			
		||||
              type = "swap";
 | 
			
		||||
            };
 | 
			
		||||
          };
 | 
			
		||||
          root = {
 | 
			
		||||
            size = "100%";
 | 
			
		||||
            content = {
 | 
			
		||||
              type = "filesystem";
 | 
			
		||||
              format = "bcachefs";
 | 
			
		||||
              mountpoint = "/";
 | 
			
		||||
              mountOptions = [
 | 
			
		||||
                "defaults"
 | 
			
		||||
              ];
 | 
			
		||||
            };
 | 
			
		||||
          };
 | 
			
		||||
        };
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue