void linux

last edited Sat, 20 Jul 2024 12:26:17 GMT
backlinks: Hipster Distributions qubesOS ricing


A barebones setup guide for my personal configuration of void. I prefer XFCE to any other desktop environment but I opt for a more minimal setup below:

Window Manager: i3

Terminal: alacritty

Image Viewer: feh

Display Manager: xrandr

Text Editor: Kakoune

Web Browser: Qutebrowser

In Fall 2023 I tested new software by ricing a fresh void musl installation.

Setting Up the Network direct link to this section

If you're using ethernet, congrats. There's more work involved if wifi wasn't set up during the installation process. wpa_supplicant is installed in the base system by default and can be used to connect to wifi until you can customize your preferred setup. The void docs contain additional details to reference.

Using wpa_passphrase to set the configuration:

 wpa_passphrase "wifi-name" "password" >> /etc/wpa_supplicant/wpa_supplicant.conf

 ip link

Then, start wpa_supplicant.

 wpa_supplicant -B -i wlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf
# link service to runit 
 ln -s /etc/sv/wpa_supplicant /var/service

Test connection with a ping. To have the settings persist through a reboot, add the line to ~/.profile (or ~/.bash_profile, ~/.zshrc, ~/.xinitrc)

wpa_supplicant -B -i wlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf

Package Management direct link to this section

Updating the System direct link to this section

Update void

xbps-install -Su

Clean System direct link to this section

sudo vkpurge rm all

Finding Software in the Repository direct link to this section

xbps-query -Rs <search>

Removing Packages direct link to this section

xbps-remove -Rf pkgname

Additonal details on flags can be found in the man pages.

Downgrading direct link to this section

XBPS makes it possible to revert packages to previous versions using xdowngrade.

Essential Software direct link to this section

Don't forget to install git, make, wget, Patch, xf, unzip, xorg. The base install is extremely minimal.

Wireguard with MullvadVPN direct link to this section

  1. download wireguard
xbps-install -S wireguard-tools wireguard-dkms

There's only 2 options, to download the official applet which is comfy and not a nightmare to use, or to manually install the configuration files yourself. The applet currently offers support to Debian, Ubuntu, Red Hat, or Fedora linux users. Because this is a void writeup we will be forced to endure the manual install. It's not as if I've only done this 4 times at this point.

You'll need to login to download the files with a generated key.

  1. download the configuration script from Mullvad's github and verify the signature file
curl -o mullvad-wg.sh https://raw.githubusercontent.com/mullvad/mullvad-wg.sh/main/mullvad-wg.sh

curl -o mullvad-wg.sh.asc https://raw.githubusercontent.com/mullvad/mullvad-wg.sh/main/mullvad-wg.sh.asc

Verify signatures

curl -o mullvad-code-signing.asc https://mullvad.net/media/mullvad-code-signing.asc

gpg --import mullvad-code-signing.asc

gpg --verify mullvad-wg.sh.asc
  1. run configuration script
chmod +x ./mullvad-wg.sh && ./mullvad-wg.sh
  1. connect with wg
wg-quick up se-mma-wg-001

To disconnect it's just the reverse of the command to connect:

wg-quick down se-mma-wg-001

after up, the specified file will correspond to the server you want to connect from, make sure to pick whichever country you want in the massive mullvad folder you downloaded.

  1. verify connection
curl https://am.i.mullvad.net/connected

Security Hardening direct link to this section

Check which user runs X server

ps -o user= -C Xorg

See Securing Linux for additional information.