Created
August 6, 2019 14:40
-
-
Save alex-pat/f2d69a91c12c614f8dcb091fd6299039 to your computer and use it in GitHub Desktop.
The rest of the owl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/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 [email protected]: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