Compare commits

...

2 Commits

6 changed files with 105 additions and 27 deletions

View File

@ -5,14 +5,15 @@
boot = {
kernelPackages = pkgs.linuxPackages_latest;
kernelParams = [ "zfs.zfs_arc_max=536870912" ];
kernelModules = [ "i915" "acpi_call" ];
kernelModules = [ "i915" "acpi_call" "kvm-intel" ];
extraModulePackages = with config.boot.kernelPackages; [ acpi_call ];
supportedFilesystems = [ "zfs" ];
zfs.requestEncryptionCredentials = true;
};
# Intel CPU tweaks
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.opengl.extraPackages = with pkgs; [
vaapiIntel
@ -70,8 +71,24 @@
users.users.coolneng = {
isNormalUser = true;
home = "/home/coolneng";
extraGroups = [ "wheel" "video" "audio" ];
shell = "/run/current-system/sw/bin/fish";
extraGroups = [ "wheel" "video" "audio" "libvirtd" ];
shell = pkgs.fish;
};
# Set fish shell for root user
users.users.root = {
shell = pkgs.fish;
openssh.authorizedKeys.keys = [
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC9mMwf7yXwtiEABwq5zkNEXgveUhNEPfqa3VLdnG2UYArB6f2l2aFM+MkGc8s84T8cj7JDF2N1pEBvilGMNWmLT32IBfwjyJov/38/PTpWb3301hCck5EOWmykGWMXdRlIEj6vsR4UqeRFwbr8QBlxv2dTPe9wTrCLvkKOuaPWMyMgtEwnNHvB8e7eqUZZYVmRSQkWCqYmK7a6TCvHUg3XsmjQU3OSmTH+eXJEUL4OiSFKxd9eO5QU04uYDbX8f8jY/slReoEWbuJ/InSWFbPs6L3bUYQrl3ht/7DR9FqzcOpAN4AcrJFyIJzot8inpp6f5IsVVjy0dhNUGWtXMkOgNf6lmylokqFBb1Jcy/lJbgUtJZ5ZNjlJFCbjXHe6J0q7bYKJgMQKuY1N3rexhZIMsBXi8aYaSKaGqX7TPnBEPlr1hXda2lGm2l6jQq5Lj2U5aj5aBa/BYmKFGVxcMpRFlsWfYPyQ/2wxRcpNcDiJt0eWP70mhu8OcupPO9kxGw0= coolneng@panacea"
];
};
# Enable localhost SSH
services.openssh = {
enable = true;
permitRootLogin = "yes";
passwordAuthentication = false;
openFirewall = false;
};
# Import other configuration modules

View File

@ -1,10 +1,10 @@
{ config, lib, pkgs, ... }:
{
# Enable ALSA
sound.enable = true;
# Enable ALSA
sound.enable = true;
# Configure PulseAudio with mopidy tweaks
# Configure PulseAudio with mopidy tweaks
hardware.pulseaudio = {
enable = true;
tcp = {
@ -12,4 +12,60 @@
anonymousClients.allowedIpRanges = [ "127.0.0.1" ];
};
};
# Set up Mopidy
services.mopidy = {
enable = true;
extensionPackages =
[ pkgs.mopidy-mpd pkgs.mopidy-soundcloud pkgs.mopidy-youtube ];
configuration = ''
[core]
cache_dir = $XDG_CACHE_DIR/cache/mopidy
config_dir = $XDG_CONFIG_DIR/mopidy
data_dir = $XDG_DATA_DIR/lib/mopidy
[logging]
config_file = $XDG_CONFIG_DIR/mopidy/logging.conf
[audio]
mixer = software
mixer_volume =
output = pulsesink server=127.0.0.1
visualizer =
[file]
enabled = true
media_dirs = /home/coolneng/Music
excluded_file_extensions =
.directory
.html
.jpeg
.jpg
.log
.nfo
.png
.txt
[mpd]
enabled = true
hostname = 127.0.0.1
port = 6600
password =
max_connections = 20
zeroconf = ""
[http]
enabled = false
[soundcloud]
enabled = false
[m3u]
playlists_dir = /home/coolneng/.config/mpd/playlists
base_dir = /home/coolneng/Music
'';
};
# Give permissions to mopidy user
users.users.mopidy = { extraGroups = [ "audio" ]; };
}

View File

@ -3,4 +3,7 @@
{
# Improve nix-shell and direnv integration
services.lorri.enable = true;
# Enable virtualization
virtualisation.libvirtd.enable = true;
}

View File

@ -5,7 +5,7 @@
services.xserver.enable = true;
services.xserver.displayManager = {
defaultSession = "sway";
sddm = {
lightdm = {
enable = true;
autoLogin = {
enable = true;
@ -34,8 +34,6 @@
kitty
];
extraSessionCommands = ''
export MOZ_ENABLE_WAYLAND=1
export MOZ_DBUS_REMOTE=1
export GRIM_DEFAULT_DIR=/home/coolneng/Photos/Screenshots
export _JAVA_AWT_WM_NONREPARENTING=1
export QT_QPA_PLATFORM=wayland
@ -48,21 +46,21 @@
programs.light.enable = true;
# Blue light filter
location = {
latitude = 35.89;
longitude = -5.32;
provider = "manual";
};
services.redshift = {
package = pkgs.redshift-wlr;
enable = true;
temperature = {
day = 6500;
night = 5000;
night = 5300;
};
};
location = {
latitude = 35.89;
longitude = -5.32;
provider = "manual";
};
# Bar
programs.waybar.enable = true;

View File

@ -1,18 +1,13 @@
{ config, lib, pkgs, ... }:
{
environment.systemPackages = with pkgs; [
avahi
wireguard
];
environment.systemPackages = with pkgs; [ avahi wireguard ];
# Set hostname and hostid
networking = {
hostName = "panacea";
hostId = "8feb0bb8";
wireless = {
enable = true;
};
wireless.enable = true;
};
# Enable zeroconf
@ -22,10 +17,11 @@
};
# Wireguard setup
networking.wireguard.interfaces = {
networking.wg-quick.interfaces = {
wg0 = {
ips = [ "10.8.0.4/32" ];
address = [ "10.8.0.4/32" ];
privateKeyFile = "/home/coolneng/.wg/keys/privatekey";
dns = [ "198.100.148.224" "151.80.222.79" ];
peers = [
# zion
{

View File

@ -11,7 +11,7 @@
passff-host
gitAndTools.pass-git-helper
# Browsers
(firefox.override { extraNativeMessagingHosts = [ passff-host ]; })
(firefox-wayland.override { extraNativeMessagingHosts = [ passff-host ]; })
chromium
# LaTeX
texlive.combined.scheme-full
@ -33,8 +33,16 @@
lorri
nixfmt
# Rice
gtk_engines
adapta-gtk-theme
paper-icon-theme
# Audio
mopidy
ncmpcpp
# Productivity
fff
zathura
libreoffice
];
# Fonts declaration