forked from jan-leila/nix-config
		
	added zfs disks to defiant
This commit is contained in:
		
							parent
							
								
									2a30c00ffb
								
							
						
					
					
						commit
						d22f470e24
					
				
					 3 changed files with 66 additions and 67 deletions
				
			
		|  | @ -63,7 +63,6 @@ | ||||||
|   systemd.targets.hibernate.enable = false; |   systemd.targets.hibernate.enable = false; | ||||||
|   systemd.targets.hybrid-sleep.enable = false; |   systemd.targets.hybrid-sleep.enable = false; | ||||||
| 
 | 
 | ||||||
|   # temp enable password auth over ssh for setup |  | ||||||
|   services.openssh = { |   services.openssh = { | ||||||
|     enable = true; |     enable = true; | ||||||
|     ports = [ 22 ]; |     ports = [ 22 ]; | ||||||
|  |  | ||||||
|  | @ -20,14 +20,14 @@ let | ||||||
|             mountpoint = "/boot"; |             mountpoint = "/boot"; | ||||||
|           }; |           }; | ||||||
|         }; |         }; | ||||||
|         root = { |         # root = { | ||||||
|           size = "100%"; |         #   size = "100%"; | ||||||
|           content = { |         #   content = { | ||||||
|             type = "filesystem"; |         #     type = "filesystem"; | ||||||
|             format = "ext4"; |         #     format = "ext4"; | ||||||
|             mountpoint = "/"; |         #     mountpoint = "/"; | ||||||
|           }; |         #   }; | ||||||
|         }; |         # }; | ||||||
|       }; |       }; | ||||||
|     }; |     }; | ||||||
|   }; |   }; | ||||||
|  | @ -52,69 +52,69 @@ in { | ||||||
|     disk = { |     disk = { | ||||||
|       boot = bootDisk "/dev/sda"; # "/dev/disk/by-path/pci-0000:23:00.3-usb-0:1:1.0-scsi-0:0:0:0"; |       boot = bootDisk "/dev/sda"; # "/dev/disk/by-path/pci-0000:23:00.3-usb-0:1:1.0-scsi-0:0:0:0"; | ||||||
| 
 | 
 | ||||||
|       # hd_13_tb_a = zfsDisk "/dev/disk/by-id/ata-ST18000NE000-3G6101_ZVTCXVEB"; |       hd_13_tb_a = zfsDisk "/dev/disk/by-id/ata-ST18000NE000-3G6101_ZVTCXVEB"; | ||||||
|       # hd_13_tb_b = zfsDisk "/dev/disk/by-id/ata-ST18000NE000-3G6101_ZVTCXWSC"; |       hd_13_tb_b = zfsDisk "/dev/disk/by-id/ata-ST18000NE000-3G6101_ZVTCXWSC"; | ||||||
|       # hd_13_tb_c = zfsDisk "/dev/disk/by-id/ata-ST18000NE000-3G6101_ZVTD10EH"; |       hd_13_tb_c = zfsDisk "/dev/disk/by-id/ata-ST18000NE000-3G6101_ZVTD10EH"; | ||||||
| 
 | 
 | ||||||
|       # ssd_2_tb_a = zfsDisk "/dev/disk/by-id/XXX"; |       # ssd_2_tb_a = zfsDisk "/dev/disk/by-id/XXX"; | ||||||
|     }; |     }; | ||||||
|     # zpool = { |     zpool = { | ||||||
|     #   zpool = { |       zpool = { | ||||||
|     #     type = "zpool"; |         type = "zpool"; | ||||||
|     #     mode = { |         mode = { | ||||||
|     #       topology = { |           topology = { | ||||||
|     #         type = "topology"; |             type = "topology"; | ||||||
|     #         vdev = [ |             vdev = [ | ||||||
|     #           { |               { | ||||||
|     #             # should this only mirror for this inital config with 3 drives we will used raidz2 for future configs??? |                 # should this only mirror for this inital config with 3 drives we will used raidz2 for future configs??? | ||||||
|     #             mode = "mirror"; |                 mode = "mirror"; | ||||||
|     #             members = [ |                 members = [ | ||||||
|     #               "hd_13_tb_a" "hd_13_tb_b" "hd_13_tb_c" |                   "hd_13_tb_a" "hd_13_tb_b" "hd_13_tb_c" | ||||||
|     #             ]; |                 ]; | ||||||
|     #           } |               } | ||||||
|     #         ]; |             ]; | ||||||
|     #         cache = [ ]; |             cache = [ ]; | ||||||
|     #         # cache = [ "ssd_2_tb_a" ]; |             # cache = [ "ssd_2_tb_a" ]; | ||||||
|     #       }; |           }; | ||||||
|     #     }; |         }; | ||||||
| 
 | 
 | ||||||
|     #     options = { |         options = { | ||||||
|     #       ashift = "12"; |           ashift = "12"; | ||||||
|     #     }; |         }; | ||||||
| 
 | 
 | ||||||
|     #     rootFsOptions = { |         rootFsOptions = { | ||||||
|     #       encryption = "on"; |           encryption = "on"; | ||||||
|     #       keyformat = "hex"; |           keyformat = "hex"; | ||||||
|     #       keylocation = "prompt"; |           keylocation = "prompt"; | ||||||
|     #       compression = "lz4"; |           compression = "lz4"; | ||||||
|     #       xattr = "sa"; |           xattr = "sa"; | ||||||
|     #       acltype = "posixacl"; |           acltype = "posixacl"; | ||||||
|     #       "com.sun:auto-snapshot" = "false"; |           "com.sun:auto-snapshot" = "false"; | ||||||
|     #     }; |         }; | ||||||
|          |          | ||||||
|     #     datasets = { |         datasets = { | ||||||
|     #       "root" = { |           "root" = { | ||||||
|     #         type = "zfs_fs"; |             type = "zfs_fs"; | ||||||
|     #         mountpoint = "/"; |             mountpoint = "/"; | ||||||
|     #       }; |           }; | ||||||
|     #       "nix" = { |           "nix" = { | ||||||
|     #         type = "zfs_fs"; |             type = "zfs_fs"; | ||||||
|     #         mountpoint = "/nix"; |             mountpoint = "/nix"; | ||||||
|     #       }; |           }; | ||||||
|     #       "home" = { |           "home" = { | ||||||
|     #         type = "zfs_fs"; |             type = "zfs_fs"; | ||||||
|     #         mountpoint = "/home"; |             mountpoint = "/home"; | ||||||
|     #         options = { |             options = { | ||||||
|     #           "com.sun:auto-snapshot" = "true"; |               "com.sun:auto-snapshot" = "true"; | ||||||
|     #         }; |             }; | ||||||
|     #       }; |           }; | ||||||
|     #       "var" = { |           "var" = { | ||||||
|     #         type = "zfs_fs"; |             type = "zfs_fs"; | ||||||
|     #         mountpoint = "/var"; |             mountpoint = "/var"; | ||||||
|     #       }; |           }; | ||||||
|     #     }; |         }; | ||||||
|     #   }; |       }; | ||||||
|     # }; |     }; | ||||||
|   }; |   }; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -71,7 +71,7 @@ | ||||||
|   # }; |   # }; | ||||||
| 
 | 
 | ||||||
|   # Enable the OpenSSH daemon. |   # Enable the OpenSSH daemon. | ||||||
|   # services.openssh.enable = true; |   services.openssh.enable = true; | ||||||
| 
 | 
 | ||||||
|   # Open ports in the firewall. |   # Open ports in the firewall. | ||||||
|   # networking.firewall.allowedTCPPorts = [ ... ]; |   # networking.firewall.allowedTCPPorts = [ ... ]; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue