Compare commits

...

10 commits

Author SHA1 Message Date
Aaron Honeycutt
4edb16d212 switch back to btrfs from luks lvm 2025-02-18 18:14:45 +00:00
Aaron Honeycutt
a3fdaabf1f download gnome.nix for nixos device 2025-02-18 17:29:48 +00:00
a691a7f19d remove workaround completely 2025-02-18 10:28:04 -07:00
Aaron Honeycutt
11c469dd12 testing to see if I can remove the workaround 2025-02-18 17:14:31 +00:00
Aaron Honeycutt
e93ce9f428 update wording for the choices 2025-02-18 16:59:35 +00:00
Aaron Honeycutt
77f1f7b88e update disko command to avoid the prompt 2025-02-18 16:53:46 +00:00
Aaron Honeycutt
014711310c fix debug 2025-02-18 16:48:21 +00:00
Aaron Honeycutt
82a7d56a2c debugging mounted error for bootloader 2025-02-18 16:45:15 +00:00
Aaron Honeycutt
1f2d03cf1a Edit install.sh 2025-02-18 16:29:28 +00:00
Aaron Honeycutt
cbb64273ae Edit install.sh 2025-02-18 16:02:29 +00:00

View file

@ -7,7 +7,10 @@ lsblk -f
echo "----------"
echo "Which drive do we want to use for this installation?"
echo "For example /dev/sda or /dev/nvme0n1"
read driveName
echo ""
read -p "Enter your drive choice: " driveName
echo ""
## Download Disko file
cd /tmp
@ -19,11 +22,17 @@ sudo sed -i "s#/dev/sda#$driveName#g" /tmp/disko-config.nix
# Step 2: Partitioning the drive used for the installation
## Run Disko to partition the disk
sudo nix --experimental-features "nix-command flakes" run github:nix-community/disko/latest -- --mode destroy,format,mount /tmp/disko-config.nix
sudo nix --experimental-features "nix-command flakes" run github:nix-community/disko/latest -- --mode destroy,format,mount /tmp/disko-config.nix --yes-wipe-all-disks
## Generate Nix configuration
sudo nixos-generate-config --no-filesystems --root /mnt
## Copies over the disko file for running `nixos-install`
sudo mv /tmp/disko-config.nix /mnt/etc/nixos
## Confirm that partitions are mounted
lsblk -f
## Downloads and places the predefinded generic flake to use
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/flake.nix > flake.nix; sudo mv -f flake.nix /mnt/etc/nixos/
@ -43,15 +52,9 @@ Which device are you installing to?
EOF
echo ""
read -p "Enter your choice: " hostChoice
read -p "Enter your device choice: " hostChoice
echo ""
## Copies over the disko file for running `nixos-install`
sudo mv /tmp/disko-config.nix /mnt/etc/nixos
## Workaround for `no free space` error
sudo nix-collect-garbage
if [ $hostChoice = 1 ]; then
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/hosts/x86_64/vm/configuration.nix > vm.nix; sudo mv -f vm.nix /mnt/etc/nixos/
sudo nixos-install --flake /mnt/etc/nixos#vm
@ -68,6 +71,7 @@ elif [ $hostChoice = 3 ]; then
elif [ $hostChoice = 0 ]; then
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/flake.nix > flake.nix; sudo mv -f flake.nix /mnt/etc/nixos/
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/desktops/gnome.nix > gnome.nix; sudo mv -f gnome.nix /mnt/etc/nixos/
sudo nixos-install --flake /mnt/etc/nixos#nixos
fi