Compare commits

...

5 Commits

Author SHA1 Message Date
81ff294468 redo pipewire module
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-04-02 16:51:32 +03:00
435b741506 modules/home/desktop/plasma/default.nix: remove stylix line
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-04-02 16:51:32 +03:00
7b30ddce63 modules/home/desktop/niri/default.nix: redo variables
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-04-02 16:51:32 +03:00
a0037fdb0f hosts/sarien/boot.nix: add security kernel params
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-04-02 16:51:32 +03:00
201db59fce hosts/eldrid/hardware.nix: fix permssions
Signed-off-by: unexplrd <unexplrd@linerds.us>
2025-04-02 16:51:32 +03:00
10 changed files with 74 additions and 21 deletions

0
hosts/eldrid/hardware.nix Executable file → Normal file
View File

View File

@ -11,6 +11,21 @@
# kernelPackages = pkgs.linuxPackages_latest;
kernelPackages = pkgs.linuxPackages_cachyos;
kernelModules = ["kvm-intel"];
kernelParams = [
"debugfs=off"
"efi=disable_early_pci_dma"
# "gather_data_sampling=force"
"intel_iommu=on"
"iommu.passthrough=0"
"iommu.strict=1"
"iommu=force"
# "lockdown=confidentiality"
# "module.sig_enforce=1"
"page_alloc.shuffle=1"
# "reg_file_data_sampling=on"
# "spec_rstack_overflow=safe-ret"
"vsyscall=none"
];
loader.efi.canTouchEfiVariables = true;
loader.systemd-boot = {
enable = true;

View File

@ -8,7 +8,8 @@
cfg = config.desktop.niri;
inherit (osConfig.networking) hostId;
inherit (config.lib.stylix) colors;
cursor_size = config.stylix.cursor.size;
cursorSize = config.stylix.cursor.size;
cursorName = config.stylix.cursor.name;
keyboard =
if hostId == "eldrid"
then "chromeos"
@ -425,8 +426,8 @@ in {
}
cursor {
xcursor-theme "${config.stylix.cursor.name}"
xcursor-size ${toString cursor_size}
xcursor-theme "${cursorName}"
xcursor-size ${toString cursorSize}
}
layout {

View File

@ -12,7 +12,6 @@ in {
mkEnableOption "enable plasma desktop";
};
config = mkIf cfg.enable {
stylix.targets.kde.enable = true;
home.packages = with pkgs; [
wl-clipboard-rs
];

View File

@ -1,21 +1,59 @@
{
config,
lib,
config,
...
}: {
security.rtkit.enable = lib.mkDefault config.services.pipewire.enable;
services = {
pulseaudio.enable = false;
pipewire = {
}: let
inherit (lib) mkEnableOption mkIf;
cfg = config.sound.pipewire;
in {
options = {
sound.pipewire.enable = mkEnableOption "enable pipewire";
};
config = mkIf cfg.enable {
security.rtkit.enable = true;
services.pulseaudio.enable = false;
services.pipewire = {
enable = true;
alsa.enable = true;
pulse.enable = true;
extraConfig.pipewire."92-low-latency" = {
context.properties.default.clock = {
rate = 48000;
quantum = 32;
min-quantum = 32;
max-quantum = 32;
extraConfig = {
pipewire = {
"92-low-latency" = {
"context.properties" = {
"default.clock.rate" = 48000;
"default.clock.allowed-rates" = [
44100
48000
88200
96000
];
"default.clock.min-quantum" = 512;
"default.clock.quantum" = 4096;
"default.clock.max-quantum" = 8192;
};
};
"93-no-resampling" = {
"context.properties" = {
"default.clock.rate" = 48000;
"default.clock.allowed-rates" = [
44100
48000
96000
192000
];
};
};
"94-no-upmixing" = {
"stream.properties" = {
"channelmix.upmix" = false;
};
};
};
};
};

View File

@ -8,7 +8,6 @@
cfg = config.desktop.cosmic;
in {
imports = with inputs; [
./common/pipewire.nix
nixos-cosmic.nixosModules.default
];
options = {
@ -16,6 +15,7 @@ in {
lib.mkEnableOption "enable cosmic desktop";
};
config = lib.mkIf cfg.enable {
sound.pipewire.enable = true;
nix.settings = {
substituters = ["https://cosmic.cachix.org/"];
trusted-public-keys = ["cosmic.cachix.org-1:Dya9IyXD4xdBehWjrkPv6rtxpmMdRel02smYzA85dPE="];

View File

@ -1,5 +1,6 @@
{
imports = [
./common/pipewire.nix
# ./cosmic.nix
./gnome.nix
./hyprland.nix

View File

@ -1,18 +1,17 @@
{
config,
pkgs,
lib,
...
}:
with lib; let
cfg = config.desktop.gnome;
in {
imports = [./common/pipewire.nix];
options = {
desktop.gnome.enable =
mkEnableOption "enable gnome desktop";
};
config = mkIf cfg.enable {
sound.pipewire.enable = true;
services.xserver = {
enable = true;
displayManager.gdm.enable = true;

View File

@ -8,12 +8,12 @@
with lib; let
cfg = config.desktop.hyprland;
in {
imports = [./common/pipewire.nix];
options = {
desktop.hyprland.enable =
mkEnableOption "enable hyprland desktop";
};
config = mkIf cfg.enable {
sound.pipewire.enable = true;
programs.hyprland = {
enable = true;
package = perSystem.hyprland.hyprland;

View File

@ -7,12 +7,12 @@
with lib; let
cfg = config.desktop.niri;
in {
imports = [./common/pipewire.nix];
options = {
desktop.niri.enable =
mkEnableOption "enable niri desktop";
};
config = mkIf cfg.enable {
sound.pipewire.enable = true;
programs.niri.enable = true;
environment.systemPackages = with pkgs; [
brightnessctl