From 5a048f0836098929ea208578264060ae848bf696 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= <joerg@thalheim.io> Date: Thu, 25 Mar 2021 09:25:28 +0100 Subject: [PATCH] document installing system from repo in rescue mode --- README.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/README.md b/README.md index 4e7aefa..4791686 100644 --- a/README.md +++ b/README.md @@ -88,3 +88,24 @@ command to also deploy secrets afterwards: ```console $ ./deploy --force-reboot --include build02 ``` + +## Install/Fix system from Hetzner recovery mode + +1. Mount all filesystems to /mnt +2. Install kexec image from Hetzner recovery system as described in [kexec.nix](infra/roles/kexec.nix) and boot into it +3. Download infra repo +``` console +$ nix-shell -p git --run "git clone https://github.com/nix-community/infra && cd infra && nix-shell" +``` + +4. Build new system closure: + +``` console +nix-shell> nix-build -A buildXX-system +``` + +5. Install system closure + +```console +$ nixos-install --system ./result +```