Initial install script in the works.
This commit is contained in:
commit
4397321c28
|
@ -0,0 +1,119 @@
|
||||||
|
# Personal Arch Linux Install Guide
|
||||||
|
|
||||||
|
I'm using this repo to record the steps I take to install and personalize arch linux.
|
||||||
|
Hopefully I can automate some of the later steps over time.
|
||||||
|
|
||||||
|
# Part 1 - Installation
|
||||||
|
|
||||||
|
Generally following the steps on the arch
|
||||||
|
[install guide](https://wiki.archlinux.org/title/Installation_guide) to
|
||||||
|
get to a chrooted environment.
|
||||||
|
|
||||||
|
- Verify we booted as x64 UEFI `cat /sys/firmware/efi/fw_platform_size`
|
||||||
|
|
||||||
|
## Network
|
||||||
|
|
||||||
|
- Check device with `ip link`
|
||||||
|
- Auth wifi with `iwctl station wlan0 connect $AP_NAME`
|
||||||
|
- `ping archlinux.org` to verify
|
||||||
|
|
||||||
|
|
||||||
|
## Partitioning
|
||||||
|
|
||||||
|
Use fdisk to partition:
|
||||||
|
/boot : 1G partition, type=1 (EFI), bootable (press M then a)
|
||||||
|
/ : remainder of the disk, default type
|
||||||
|
|
||||||
|
For /boot (/dev/sda1) call `mkfs.fat -F 32 /dev/sda1`
|
||||||
|
|
||||||
|
Follow the steps
|
||||||
|
[here](https://wiki.archlinux.org/title/Dm-crypt/Encrypting_an_entire_system#LUKS_on_a_partition)
|
||||||
|
to encrypt the root partition. Consider increasing the cryptographic parameters as mentions.
|
||||||
|
|
||||||
|
Mount the partitions at /mnt and /mnt/boot.
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
|
Install the base:
|
||||||
|
`pacstrap -K /mnt base linux linux-firmware`
|
||||||
|
|
||||||
|
Followed by important packages:
|
||||||
|
`pacstrap /mnt grub efibootmgr e2fsprogs networkmanager vim man-db man-pages texinfo sudo`
|
||||||
|
|
||||||
|
# Part 2 - Configure
|
||||||
|
|
||||||
|
Generally follow the configure the system steps in the
|
||||||
|
[install guide](https://wiki.archlinux.org/title/Installation_guide#Configure_the_system).
|
||||||
|
|
||||||
|
`genfstab -U /mnt >> /mnt/etc/fstab`
|
||||||
|
|
||||||
|
`arch-chroot /mnt`
|
||||||
|
|
||||||
|
- Set the time as described.
|
||||||
|
- Set the localization as described.
|
||||||
|
- Enable NetworkManager `systemctl enable NetworkManager.service`
|
||||||
|
- Update the initramfs as described
|
||||||
|
[here](https://wiki.archlinux.org/title/Dm-crypt/Encrypting_an_entire_system#Configuring_mkinitcpio)
|
||||||
|
|
||||||
|
- Set the root password
|
||||||
|
|
||||||
|
- Run `grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB`
|
||||||
|
- Update `/etc/default/grub` to have the line:
|
||||||
|
`GRUB_CMDLINE_LINUX="cryptdevice=UUID=device-UUID:root root=/dev/mapper/root"`
|
||||||
|
- Run `grub-mkconfig -o /boot/grub/grub.cfg`
|
||||||
|
|
||||||
|
- Reboot sucessfully(?) into the new system.
|
||||||
|
|
||||||
|
## In the new system
|
||||||
|
|
||||||
|
Connect to wifi
|
||||||
|
- `nmcli device wifi list`
|
||||||
|
- `nmcli device wifi connect --ask $SSID`
|
||||||
|
- `nmcli c modify $SSID connection.autoconnect true`
|
||||||
|
|
||||||
|
Create a user:
|
||||||
|
- `useradd -m -G wheel drew`
|
||||||
|
- `EDITOR=vim visudo` and uncomment the line starting %wheel
|
||||||
|
|
||||||
|
Install helpful utilities:
|
||||||
|
|
||||||
|
- `pacman -S git`
|
||||||
|
|
||||||
|
TODO: Install graphics driver pagckages?
|
||||||
|
|
||||||
|
# Part 3 - Desktop
|
||||||
|
|
||||||
|
Reboot and login as the new user.
|
||||||
|
|
||||||
|
Clone this git repo at /home/drew/install.
|
||||||
|
|
||||||
|
Run `sudo ./install_desktop.sh`
|
||||||
|
|
||||||
|
# Part 4 - Applications
|
||||||
|
|
||||||
|
`mkdir Documents/ Downloads/ Pictures/`
|
||||||
|
`sudo pacman -S firefox`
|
||||||
|
|
||||||
|
Log into firefox w/ sync (installs bitwarden.)
|
||||||
|
|
||||||
|
# Part 5 - Dev environment
|
||||||
|
|
||||||
|
`sudo pacman -S neovim lua-language-server ccls rust rust-analyzer jedi-language-server`
|
||||||
|
|
||||||
|
Start up neovim and run PackerSync
|
||||||
|
(note you may have to comment out:
|
||||||
|
init.lua: require(impatient)
|
||||||
|
opts.lua: vim.cmd("colorscheme nordfox")
|
||||||
|
|
||||||
|
|
||||||
|
Add ssh keys to gitea and gitlab.
|
||||||
|
|
||||||
|
mkdir prog and clone a c++ code base, a python code base, and a rust code base to test the language server.
|
||||||
|
|
||||||
|
|
||||||
|
# Part 6 - Optional
|
||||||
|
|
||||||
|
Steam?
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,69 @@
|
||||||
|
# /bin/bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
if [[ $EUID -ne 0 ]]; then
|
||||||
|
echo "Must run as root."
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
echo "Installing packages."
|
||||||
|
# Base Packages.
|
||||||
|
sudo pacman -S which base-devel
|
||||||
|
|
||||||
|
# Display Elements.
|
||||||
|
sudo pacman -S plymouth sddm wayland sway swaybg swaylock swayidle wofi waybar
|
||||||
|
|
||||||
|
# Theming.
|
||||||
|
sudo pacman -S ttf-liberation sddm kitty zsh adobe-source-code-pro-fonts ttf-sourcecodepro-nerd ttf-dejavu arc-gtk-theme papirus-icon-theme
|
||||||
|
|
||||||
|
|
||||||
|
echo "Installing yay"
|
||||||
|
mkdir opt
|
||||||
|
pushd opt
|
||||||
|
git clone https://aur.archlinux.org/yay.git
|
||||||
|
pushd yay
|
||||||
|
makepkg -si
|
||||||
|
popd
|
||||||
|
popd
|
||||||
|
|
||||||
|
|
||||||
|
echo "Installing plymouth"
|
||||||
|
# This is likely a bit too brittle.
|
||||||
|
sed -i 's/kms keyboard/kms plymouth keyboard/' /etc/mkinitcpio.conf
|
||||||
|
mkinitcpio -P
|
||||||
|
sed -i 's/GRUB_CMDLINE_LINUX_DEFAULT="/GRUB_CMDLINE_LINUX_DEFAULT="splash /' /etc/default/grub
|
||||||
|
grub-mkconfig -o /boot/grub/grub.cfg
|
||||||
|
|
||||||
|
echo "Installing plymouth theme"
|
||||||
|
yay -S plymouth-theme-deus-ex-git
|
||||||
|
plymouth-set-default-theme -R deus_ex
|
||||||
|
|
||||||
|
echo "Pulling home git config"
|
||||||
|
$CONFIG='/usr/bin/git --git-dir=/home/drew/.cfg/ --work-tree=/home/drew'
|
||||||
|
git config --global init.defaultBranch main
|
||||||
|
mkdir ~/.cfg
|
||||||
|
$CONFIG init
|
||||||
|
$CONFIG remote add origin https://gitlab.com/dgalbraith33/dotfiles.git
|
||||||
|
$CONFIG pull origin main
|
||||||
|
$CONFIG submodule update --init
|
||||||
|
echo "*" > ~/.gitignore
|
||||||
|
|
||||||
|
echo "Enabling SDDM"
|
||||||
|
systemctl enable sddm
|
||||||
|
yay -S sddm-sugar-dark
|
||||||
|
mkdir /etc/sddm.conf.d
|
||||||
|
echo "[Theme]\nCurrent=sugar-dark" | tee /etc/sddm.conf.d/theme.conf
|
||||||
|
echo "[General]\nDisplayServer=Wayland" | tee /etc/sddm.conf.d/theme.conf
|
||||||
|
sed -i 's/ForceHideCompletePassword=false/ForceHideCompletePassword=true/' /usr/share/sddm/themes/sugar-dark/theme.conf
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
echo "Giving Sway hardware access."
|
||||||
|
usermod -aG seat drew
|
||||||
|
systemctl enable seatd.service
|
||||||
|
|
||||||
|
|
||||||
|
pacman -S pulseaudio pavucontrol network-manager-applet
|
||||||
|
|
||||||
|
echo "3. Add splash to kernel parameters in /etc/default/grub and run grub-mkconfig -o /boot/grub/grub.cfg"
|
Loading…
Reference in New Issue