nix-config/phone/configuration.nix
Donovan Glover af678f14d9
phone: Improve virtualization support
Makes things snappier among other things.
2024-06-15 13:49:47 -04:00

139 lines
2.2 KiB
Nix

{ pkgs, ... }:
let
username = "user";
in
{
environment = {
sessionVariables = {
LIBGL_ALWAYS_SOFTWARE = "true";
};
shells = with pkgs; [
fish
];
systemPackages = with pkgs; [
flare-signal
gurk-rs
anki
android-tools
wget
chatty
gnome-console
megapixels
kitty
neovim
fish
yazi
bat
w3m
librewolf
git
htop-vim
gnupg
mpv
ncmpcpp
pqiv
qutebrowser
starship
eza
fd
fzf
ripgrep
yt-dlp
neofetch
genact
zellij
p7zip
unar
];
defaultPackages = [ ];
};
programs = {
fish.enable = true;
neovim.enable = true;
calls.enable = true;
command-not-found.enable = false;
};
networking = {
hostName = "mobile-nixos";
wireless.enable = false;
wireguard.enable = true;
networkmanager = {
enable = true;
wifi.macAddress = "random";
ethernet.macAddress = "random";
};
};
hardware = {
pulseaudio = {
enable = true;
package = pkgs.pulseaudioFull;
};
bluetooth.enable = true;
sensor.iio.enable = true;
};
services = {
openssh.enable = true;
resolved.llmnr = "false";
xserver.desktopManager.phosh = {
enable = true;
group = "users";
user = username;
};
};
users = {
defaultUserShell = pkgs.fish;
users.${username} = {
isNormalUser = true;
description = username;
password = username;
extraGroups = [
"dialout"
"feedbackd"
"networkmanager"
"video"
"wheel"
];
};
};
virtualisation.vmVariant = {
virtualisation = {
memorySize = 4096;
cores = 4;
sharedDirectories = {
tmp = {
source = "/tmp";
target = "/mnt";
};
};
qemu.options = [
"-device virtio-vga-gl"
"-display sdl,gl=on,show-cursor=off"
"-audio pa,model=hda"
"-full-screen"
];
};
};
powerManagement.enable = true;
zramSwap.enable = true;
nix.settings.experimental-features = [ "nix-command" "flakes" "repl-flake" ];
system.stateVersion = "23.11";
}