Skip to content

Instantly share code, notes, and snippets.

@alex-pat
Created August 6, 2019 14:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alex-pat/f2d69a91c12c614f8dcb091fd6299039 to your computer and use it in GitHub Desktop.
Save alex-pat/f2d69a91c12c614f8dcb091fd6299039 to your computer and use it in GitHub Desktop.
The rest of the owl
#!/usr/bin/env bash
# partitions
parted /dev/sda -- mklabel msdos
parted /dev/sda -- mkpart primary 1MiB 100%
mkfs.ext4 -L nixos /dev/sda1
mount /dev/sda1 /mnt
# nixos
nixos-generate-config --root /mnt
# (download ssh keys)
# edit /mnt/etc/nixos/configuration.nix
# (maybe gist with initial config)
mkdir /mnt/home/postskript/.ssh
# cp keys
# reboot
# login as root
passwd postskript
# login as postskript
# fix login
git clone git@github.com:alex-pat/nix-config.git
sudo ln -sf /home/postskript/nix-config/nixos/configuration.nix /etc/nixos/configuration.nix
cd nix-config
git submodule update --init --recursive --progress
for i in awesome fish termite zathura ; do
mkdir ~/.config/$i
done
for i in awesome fish git nixos scripts termite vim zathura ; do
stow $i
done
sudo nixos-rebuild switch
gpg2 --import $key
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment