wolverian / dotfiles

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Setting up a new NixOS installation

  • Boot a new VM using the nixos live CD with root password set to "root"
  • Check the ip number of the VM: ifconfig
  • Update the Makefile with the ip and then run make bootstrap in the host
    • Sometimes the disk partitions get a p prefix, like for nvme0n1 so you need to add p<number> as suffix
  • run make install
  • The previous step will reboot into the live CD again, remove the media, and reboot the VM.
  • ssh to the VM ssh root@<ip>
  • mv /etc/nixos/dotfiles /home/antti/dotfiles && chown antti:users -R /home/antti/dotfiles
  • Change remote origin to git@github.com:anttih/dotfiles.git
  • rm /etc/nixos/configuration.nix
  • Set password for antti with sudo passwd antti
  • scp the private and public key to the machine
  • ssh-add ~/.ssh/<key>

Rebuilding

$ sudo nixos-rebuild switch --flake .#<host>

About


Languages

Language:Nix 47.5%Language:Lua 24.4%Language:Vim Script 22.0%Language:Shell 2.9%Language:Makefile 2.4%Language:Nu 0.8%