diff options
author | EuAndreh <eu@euandre.org> | 2018-03-23 20:38:44 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2018-03-23 20:49:09 -0300 |
commit | 4e734232c611890f616194ed5cfade2549e4491b (patch) | |
tree | 38e74c5f28aaa8ecc8c6cbff7836d919c8fa7a1b /nixos/os-installation.sh | |
parent | Initial commit: add git-crypt .gitattributes file (diff) | |
download | dotfiles-4e734232c611890f616194ed5cfade2549e4491b.tar.gz dotfiles-4e734232c611890f616194ed5cfade2549e4491b.tar.xz |
Initial commit: now public (again)
Diffstat (limited to 'nixos/os-installation.sh')
-rw-r--r-- | nixos/os-installation.sh | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/nixos/os-installation.sh b/nixos/os-installation.sh new file mode 100644 index 0000000..827b820 --- /dev/null +++ b/nixos/os-installation.sh @@ -0,0 +1,83 @@ +sudo umount /dev/sdc1 +sudo dd if=os.iso of=/dev/sdc # + +# Derived from https://www.maketecheasier.com/nixos-review/ + +# First, connect an ethernet cable + +loadkeys br-abnt2 +fdisk /dev/sda + +# START Steps within fdisk +# First, delete all partitions with `d` +o + +n +p +1 +ENTER ++2G +t +82 + +n +p +2 +ENTER +ENTER + +a +2 + +w +# END Steps within fdisk + +mkswap -L swap /dev/sda1 +swapon /dev/sda1 +mkfs.ext4 -L nixos /dev/sda2 +mount /dev/disk/by-label/nixos /mnt +nixos-generate-config --root /mnt + +# START Edit NixOS configuration file +vi /mnt/etc/nixos/configuration.nix + +# Uncomment: +boot.loader.grub.device = “/dev/sda” +enviroment.systemPackages = with pkgs; [ + wget + vim + firefox + gitAndTools.gitFull + gitAndTools.git-annex + gitAndTools.gitRemoteGcrypt + lsof + gnupg + gnupg1 +] + +# Add: +services = { + xserver = { + enable = true; + desktopManager.gnome3.enable = true; + displayManager.gdm.enable = true; + }; +}; +# END + +nixos-install + +# OS will prompt for root UNIX password + +reboot + + +C-M-<F1> + useradd -m andreh + passwd andreh + # Setup UNIX password (for andreh) + + sudo vi /etc/sudoers + # START Add the following line below the `root` line + andreh ALL=(ALL) ALL + # END |