382b5640f80e736d95978bbc0e378fc46eb2224f
Installing
Fresh system (nixos USB drive)
- Open a nix-shell with git:
nix-shell -p git
- Clone the flake
git clone https://git.lajuntament.space/marc/samfelag.git
-
Partition the disk
- Locate the disk
lsblk- Create a GPT partition table
sudo parted /dev/nvme0n1 -- mklabel gpt- Create the root partition
sudo parted /dev/nvme0n1 -- mkpart primary 512MB -8GB- Create the swap partition
sudo parted /dev/nvme0n1 -- mkpart primary linux-swap -8GB 100%- Create the boot partition
sudo parted /dev/nvme0n1 -- mkpart ESP fat32 1MB 512MB sudo parted /dev/nvme0n1 -- set 3 esp on -
Format the partitions
- Root partition
sudo mkfs.ext4 -L nixos /dev/nvme0n1p1- Swap partition
sudo mkswap -L swap /dev/nvme0n1p2- Boot partition
sudo mkfs.fat -F 32 -n BOOT /dev/nvme0n1p3 -
Mount the filesystems
- Root partition
sudo mount /dev/disk/by-label/nixos /mnt- Boot partition
sudo mkdir -p /mnt/boot sudo mount /dev/disk/by-label/BOOT /mnt/boot- Swap partition (if needed)
sudo swapon /dev/disk/by-label/swap - Create the host nix configuration
If the host is not present under system/hosts, create a new folder for the host. Generate the hardware configuration file, you can use nixos-generate-config as a base:
nixos-generate-config --dir <<host directory>> --no-filesystems
- Install nixos!
sudo nixos-install --impure --root /mnt --flake .#reykjavik
Description
Languages
Nix
52.6%
Emacs Lisp
20%
Shell
13.4%
HCL
12.8%
SCSS
1.2%