From eb5afef7930783349c8408f5e9a4a01954e33578 Mon Sep 17 00:00:00 2001
From: Jean-Paul Calderone <exarkun@twistedmatrix.com>
Date: Tue, 5 Nov 2019 09:18:07 -0500
Subject: [PATCH] expand

---
 morph/README.rst              | 23 +++++++++++++++++++++++
 morph/testing001-hardware.nix |  7 +++++++
 2 files changed, 30 insertions(+)

diff --git a/morph/README.rst b/morph/README.rst
index 3bb77dca..05169380 100644
--- a/morph/README.rst
+++ b/morph/README.rst
@@ -55,6 +55,29 @@ starting from a minimal NixOS 19.03 or 19.09 installation.
 #. Add ``"zfs"`` to ``boot.supportedFilesystems`` in ``storageNNN-hardware.nix``.
 #. Create a ``storageNNN-config.nix`` containing further configuration for the new host.
 #. Add an entry for the new host to ``grid.nix`` referencing the new files.
+#. Deploy to the new host with ``morph deploy morph/grid.nix --on <identifier> boot``.
+#. Log on to the new host and reboot it.
+#. Log on to the new host and manually create a storage zpool::
+
+     zpool create -m legacy -o ashift=12 root raidz /dev/disk/by-id/{...}
+
+#. Mount the new ZFS filesystem to verify it is working::
+
+     mkdir /storage
+     mount -t zfs root /storage
+
+#. Add a new filesystem entry to ``storageNNN-hardware.nix``::
+
+     # Manually created using:
+     #   zpool create -f -m legacy -o ashift=12 root raidz ...
+     fileSystems."/storage" = {
+       device = "root";
+       fsType = "zfs";
+     };
+
+#. Deploy the new configuration to the host::
+
+     morph deploy morph/grid.nix --on <identifier> switch --reboot
 
 
 .. _`morph`: https://github.com/DBCDK/morph
diff --git a/morph/testing001-hardware.nix b/morph/testing001-hardware.nix
index c00834cf..958a2478 100644
--- a/morph/testing001-hardware.nix
+++ b/morph/testing001-hardware.nix
@@ -4,4 +4,11 @@
 
   boot.supportedFilesystems = [ "zfs" ];
   networking.hostId = "10000000";
+
+  # Manually created using:
+  #   zpool create -m legacy -o ashift=12 root raidz /dev/disk/by-id/{nvme-nvme.1d0f-766f6c3038623133353836383465643436363430-416d617a6f6e20456c617374696320426c6f636b2053746f7265-00000001,nvme-nvme.1d0f-766f6c3034653531383066303134633436653034-416d617a6f6e20456c617374696320426c6f636b2053746f7265-00000001,nvme-nvme.1d0f-766f6c3062333164633831386366623231373730-416d617a6f6e20456c617374696320426c6f636b2053746f7265-00000001,nvme-nvme.1d0f-766f6c3061353939623438336661353933636664-416d617a6f6e20456c617374696320426c6f636b2053746f7265-00000001}
+  fileSystems."/storage" = {
+    device = "root";
+    fsType = "zfs";
+  };
 }
-- 
GitLab