initial configuration

This commit is contained in:
2024-03-09 17:18:36 +01:00
commit b51cdf718a
41 changed files with 1741 additions and 0 deletions

View File

@@ -0,0 +1,23 @@
{ config, pkgs, ... }:
{
programs.hyprland = {
enable = true;
xwayland.enable = true;
};
# Configure display manager
services.greetd = {
enable = true;
settings = {
default_session = {
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --remember --time --cmd Hyprland";
user = "xeovalyte";
};
};
};
# Configure networking
networking.networkmanager.enable = true;
networking.wireless.iwd.enable = true;
}

View File

@@ -0,0 +1,34 @@
{ ... }:
{
services.syncthing = {
enable = true;
user = "xeovalyte";
dataDir = "/home/xeovalyte";
overrideDevices = true;
overrideFolders = true;
openDefaultPorts = true;
settings = {
devices = {
"xv-server" = {
id = "DYBGKGM-I7JM6NG-EV7EGYY-NZL5WCG-CSDSJCJ-B4Q7AOP-5YVQYAZ-ETLQWA5";
addresses = [
"dynamic"
"tcp://ddns.xeovalyte.com:22000"
"quick://ddns.xeovalyte.com:22000"
];
};
};
folders = {
"xeovalyte-documents" = { # Name of folder in Syncthing, also the folder ID
path = "/home/xeovalyte/Documents"; # Which folder to add to Syncthing
devices = [ "xv-server" ]; # Which devices to share the folder with
};
"xeovalyte-logseq" = { # Name of folder in Syncthing, also the folder ID
path = "/home/xeovalyte/Logseq"; # Which folder to add to Syncthing
devices = [ "xv-server" ]; # Which devices to share the folder with
};
};
};
};
}

View File

@@ -0,0 +1,14 @@
{ pkgs, ... }:
{
programs.thunar = {
enable = true;
plugins = with pkgs.xfce; [
thunar-archive-plugin
thunar-volman
];
};
services.gvfs.enable = true;
services.tumbler.enable = true;
}

View File

@@ -0,0 +1,10 @@
{ pkgs, ... }:
{
environment.systemPackages = with pkgs; [
usbutils
neofetch
btop
git
];
}

View File

@@ -0,0 +1,33 @@
{ lib, pkgs, ... }:
{
services.fprintd.enable = true;
security.pam.services.hyprlock = {
text = ''
auth sufficient pam_unix.so try_first_pass likeauth nullok
auth sufficient ${pkgs.fprintd}/lib/security/pam_fprintd.so
auth include login
'';
};
security.pam.services.greetd = {
text = ''
account required pam_unix.so # unix (order 10900)
# Authentication management.
auth sufficient pam_unix.so likeauth nullok try_first_pass # unix (order 11600)
auth sufficient /nix/store/bz12s6mba297725i9y35p73lvsic8gd3-fprintd-1.94.2/lib/security/pam_fprintd.so # fprintd (order 11400)
auth required pam_deny.so # deny (order 12400)
# Password management.
password sufficient pam_unix.so nullok yescrypt # unix (order 10200)
# Session management.
session required pam_env.so conffile=/etc/pam/environment readenv=0 # env (order 10100)
session required pam_unix.so # unix (order 10200)
session required pam_loginuid.so # loginuid (order 10300)
session optional /nix/store/dzp7d4k1d94s1x49p9171mvcsfyxr7bj-systemd-254.6/lib/security/pam_systemd.so # systemd (order 12000) login
'';
};
}

View File

@@ -0,0 +1,11 @@
{ ... }:
{
nix.gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 1w";
};
nix.settings.auto-optimise-store = true;
}

View File

@@ -0,0 +1,18 @@
{ ... }:
{
services.auto-cpufreq.enable = true;
services.auto-cpufreq.settings = {
battery = {
governor = "powersave";
turbo = "never";
};
charger = {
governor = "performance";
turbo = "auto";
};
};
powerManagement.powertop.enable = true;
}