Fixed installation steps

This commit is contained in:
Marc Sastre Rienitz
2022-11-03 21:14:32 +00:00
parent 009e7574e0
commit 382b5640f8

View File

@@ -18,7 +18,59 @@ git clone https://git.lajuntament.space/marc/samfelag.git
lsblk lsblk
#+END_SRC #+END_SRC
1. Create a GPT partition table
#+BEGIN_SRC bash
sudo parted /dev/nvme0n1 -- mklabel gpt
#+END_SRC
1. Create the root partition
#+BEGIN_SRC bash
sudo parted /dev/nvme0n1 -- mkpart primary 512MB -8GB
#+END_SRC
1. Create the swap partition
#+BEGIN_SRC bash
sudo parted /dev/nvme0n1 -- mkpart primary linux-swap -8GB 100%
#+END_SRC
1. Create the boot partition
#+BEGIN_SRC bash
sudo parted /dev/nvme0n1 -- mkpart ESP fat32 1MB 512MB
sudo parted /dev/nvme0n1 -- set 3 esp on
#+END_SRC
1. Format the partitions
1. Root partition
#+BEGIN_SRC bash
sudo mkfs.ext4 -L nixos /dev/nvme0n1p1
#+END_SRC
1. Swap partition
#+BEGIN_SRC bash
sudo mkswap -L swap /dev/nvme0n1p2
#+END_SRC
1. Boot partition
#+BEGIN_SRC bash
sudo mkfs.fat -F 32 -n BOOT /dev/nvme0n1p3
#+END_SRC
1. Mount the filesystems 1. Mount the filesystems
1. Root partition
#+BEGIN_SRC bash
sudo mount /dev/disk/by-label/nixos /mnt
#+END_SRC
1. Boot partition
#+BEGIN_SRC bash
sudo mkdir -p /mnt/boot
sudo mount /dev/disk/by-label/BOOT /mnt/boot
#+END_SRC
1. Swap partition (if needed)
#+BEGIN_SRC bash
sudo swapon /dev/disk/by-label/swap
#+END_SRC
1. Create the host nix configuration 1. Create the host nix configuration
If the host is not present under system/hosts, create a new folder for the host. If the host is not present under system/hosts, create a new folder for the host.
@@ -31,5 +83,5 @@ nixos-generate-config --dir <<host directory>> --no-filesystems
1. Install nixos! 1. Install nixos!
#+BEGIN_SRC bash #+BEGIN_SRC bash
sudo nixos-install --impure --flake .#reykjavik sudo nixos-install --impure --root /mnt --flake .#reykjavik
#+END_SRC #+END_SRC