From d5644d2def423e45b88fc769cbda3544d9170a6c Mon Sep 17 00:00:00 2001
From: hensoko <hensoko@noreply.git.pub.solar>
Date: Mon, 17 Feb 2025 19:03:29 +0000
Subject: [PATCH] Update docs/nixos-anywhere.md

---
 docs/nixos-anywhere.md | 27 +++++++++++++++------------
 1 file changed, 15 insertions(+), 12 deletions(-)

diff --git a/docs/nixos-anywhere.md b/docs/nixos-anywhere.md
index e7d5681..8cabce9 100644
--- a/docs/nixos-anywhere.md
+++ b/docs/nixos-anywhere.md
@@ -1,17 +1,6 @@
 # Deploying with nixos-anywhere
 
-## Basic steps
-
-```
-mkdir -p /etc/secrets/initrd
-ssh-keygen -t ed25519 -f /etc/secrets/initrd/ssh_host_ed25519_key
-```
-
-```
-nix run github:nix-community/nixos-anywhere -- --flake .#<host> root@<ip>
-```
-
-## Enter NixOS from non-NixOS host
+## On Target: Enter NixOS from non-NixOS host
 
 In case you cannot boot easily into a nixos-installer image you can download the kexec installer image of NixOS and kexec into it: 
 
@@ -19,3 +8,17 @@ In case you cannot boot easily into a nixos-installer image you can download the
 curl -L https://github.com/nix-community/nixos-images/releases/download/nixos-unstable/nixos-kexec-installer-noninteractive-x86_64-linux.tar.gz | tar -xzf- -C /root
 /root/kexec/run
 ```
+
+## On Target: Create inital ssh host key used in initrd
+
+```
+mkdir -p /etc/secrets/initrd
+ssh-keygen -t ed25519 -f /etc/secrets/initrd/ssh_host_ed25519_key
+```
+
+## Run NixOS Anywhere
+
+```
+nix run github:nix-community/nixos-anywhere -- --flake .#<host> root@<ip>
+```
+