Update a lot of options, simplify variables, replace options with tags
This commit is contained in:
parent
dbc0ab6dd3
commit
7667ef9a1b
147 changed files with 663 additions and 928 deletions
12
flake.lock
generated
12
flake.lock
generated
|
@ -523,11 +523,11 @@
|
||||||
},
|
},
|
||||||
"stable": {
|
"stable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1748437600,
|
"lastModified": 1749024892,
|
||||||
"narHash": "sha256-hYKMs3ilp09anGO7xzfGs3JqEgUqFMnZ8GMAqI6/k04=",
|
"narHash": "sha256-OGcDEz60TXQC+gVz5sdtgGJdKVYr6rwdzQKuZAJQpCA=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "7282cb574e0607e65224d33be8241eae7cfe0979",
|
"rev": "8f1b52b04f2cb6e5ead50bd28d76528a2f0380ef",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -589,11 +589,11 @@
|
||||||
},
|
},
|
||||||
"unstable": {
|
"unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1748460289,
|
"lastModified": 1748929857,
|
||||||
"narHash": "sha256-7doLyJBzCllvqX4gszYtmZUToxKvMUrg45EUWaUYmBg=",
|
"narHash": "sha256-lcZQ8RhsmhsK8u7LIFsJhsLh/pzR9yZ8yqpTzyGdj+Q=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "96ec055edbe5ee227f28cdbc3f1ddf1df5965102",
|
"rev": "c2a03962b8e24e669fb37b7df10e7c79531ff1a4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
tags = [
|
|
||||||
"latptop"
|
|
||||||
"pc"
|
|
||||||
];
|
|
||||||
targetHost = "";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -11,7 +10,9 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
desktop.enable = true;
|
nixos.tags = [ "pc" ];
|
||||||
stateVersion = "25.05";
|
stateVersion = "25.05";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
{ config, nodes, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
fileSystems = with config.sysusers; with nodes; {
|
fileSystems = {
|
||||||
# Local mounts
|
|
||||||
"/persist/storage" = {
|
"/persist/storage" = {
|
||||||
device = "/dev/disk/by-uuid/d0d6783f-ad51-4d85-b8a9-3374f6460ef6";
|
device = "/dev/disk/by-uuid/d0d6783f-ad51-4d85-b8a9-3374f6460ef6";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
|
@ -11,43 +10,10 @@
|
||||||
"subvol=storage"
|
"subvol=storage"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
"/persist/home/${main}/games" = {
|
|
||||||
device = "/dev/disk/by-uuid/d0d6783f-ad51-4d85-b8a9-3374f6460ef6";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [
|
|
||||||
"nofail"
|
|
||||||
"nosuid"
|
|
||||||
"subvol=games"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Network mounts
|
# Network mounts
|
||||||
"/home/${main}/Network/Midas" = {
|
"kitty".enable = true;
|
||||||
device = "[${midas.config.deployment.targetHost}]:/storage";
|
"midas".enable = true;
|
||||||
fsType = "nfs4";
|
"prophet".enable = true;
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Kitty" = {
|
|
||||||
device = "[${kitty.config.deployment.targetHost}]:/storage/bun";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Prophet" = {
|
|
||||||
device = "[${prophet.config.deployment.targetHost}]:/storage";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, modulesPath, ... }:
|
{ modulesPath, ... }:
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
|
@ -17,6 +17,7 @@
|
||||||
kernelModules = [ "kvm-intel" ];
|
kernelModules = [ "kvm-intel" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}" = {
|
home-manager.users."${config.vars.mainUser}" = {
|
||||||
home = {
|
home = {
|
||||||
desktop.enable = true;
|
desktop.enable = true;
|
||||||
gaming.enable = true;
|
gaming.enable = true;
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
tags = [
|
|
||||||
"misc"
|
|
||||||
"pc"
|
|
||||||
];
|
|
||||||
targetHost = "4ec:1001:ca5a:ae79:40e2:cb4c:e3c9:f401";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,8 +1,7 @@
|
||||||
{ lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./hardware
|
./hardware
|
||||||
./services
|
./services
|
||||||
|
@ -11,7 +10,9 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
desktop.enable = true;
|
nixos.tags = [ "pc" ];
|
||||||
stateVersion = "24.11";
|
stateVersion = "24.11";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "4ec:1001:ca5a:ae79:40e2:cb4c:e3c9:f401";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, modulesPath, ... }:
|
{ modulesPath, ... }:
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
|
@ -18,6 +18,10 @@
|
||||||
kernelModules = [ "kvm-intel" ];
|
kernelModules = [ "kvm-intel" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu = {
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
amd.updateMicrocode = true;
|
||||||
|
intel.updateMicrocode = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}".home = {
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
desktop.enable = true;
|
desktop.enable = true;
|
||||||
school.enable = true;
|
school.enable = true;
|
||||||
stateVersion = lib.mkForce config.system.stateVersion;
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
tags = [
|
|
||||||
"latptop"
|
|
||||||
"pc"
|
|
||||||
];
|
|
||||||
targetHost = "40e:404:a427:da33:163e:97b3:a2a3:9ed4";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -11,7 +10,9 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
desktop.enable = true;
|
nixos.tags = [ "pc" ];
|
||||||
stateVersion = "24.11";
|
stateVersion = "24.11";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "40e:404:a427:da33:163e:97b3:a2a3:9ed4";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,33 +1,9 @@
|
||||||
{ config, nodes, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
fileSystems = with config.sysusers; with nodes; {
|
fileSystems = {
|
||||||
# Network mounts
|
# Network mounts
|
||||||
"/home/${main}/Network/Midas" = {
|
"kitty".enable = true;
|
||||||
device = "[${midas.config.deployment.targetHost}]:/storage";
|
"midas".enable = true;
|
||||||
fsType = "nfs4";
|
"prophet".enable = true;
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Kitty" = {
|
|
||||||
device = "[${kitty.config.deployment.targetHost}]:/storage/bun";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Prophet" = {
|
|
||||||
device = "[${prophet.config.deployment.targetHost}]:/storage";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, modulesPath, ... }:
|
{ modulesPath, ... }:
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
||||||
kernelModules = [ "kvm-intel" ];
|
kernelModules = [ "kvm-intel" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}".home = {
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
desktop.enable = true;
|
desktop.enable = true;
|
||||||
production.enable = true;
|
production.enable = true;
|
||||||
stateVersion = lib.mkForce config.system.stateVersion;
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
tags = [
|
|
||||||
"latptop"
|
|
||||||
"pc"
|
|
||||||
];
|
|
||||||
targetHost = "5ce:969c:40d1:9575:f5e:591d:c377:a20b";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -13,8 +12,10 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
desktop.enable = true;
|
nixos.tags = [ "pc" ];
|
||||||
steamdeck.enable = true;
|
steamdeck.enable = true;
|
||||||
stateVersion = "24.11";
|
stateVersion = "24.11";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "5ce:969c:40d1:9575:f5e:591d:c377:a20b";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
{ config, nodes, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
fileSystems = with config.sysusers; with nodes; {
|
fileSystems = {
|
||||||
# Local mounts
|
|
||||||
"/mnt/Games" = {
|
"/mnt/Games" = {
|
||||||
device = "/dev/disk/by-uuid/cb109a85-846d-4417-9c50-a2279bd20803";
|
device = "/dev/disk/by-uuid/cb109a85-846d-4417-9c50-a2279bd20803";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
|
@ -12,32 +11,8 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
# Network mounts
|
# Network mounts
|
||||||
"/home/${main}/Network/Midas" = {
|
"kitty".enable = !config.system.steamdeck.enable;
|
||||||
device = "[${midas.config.deployment.targetHost}]:/storage";
|
"midas".enable = !config.system.steamdeck.enable;
|
||||||
fsType = "nfs4";
|
"prophet".enable = !config.system.steamdeck.enable;
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Kitty" = {
|
|
||||||
device = "[${kitty.config.deployment.targetHost}]:/storage/bun";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Prophet" = {
|
|
||||||
device = "[${prophet.config.deployment.targetHost}]:/storage";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, modulesPath, ... }:
|
{ modulesPath, ... }:
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
|
@ -15,6 +15,7 @@
|
||||||
kernelModules = [ "kvm-amd" ];
|
kernelModules = [ "kvm-amd" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu.amd.updateMicrocode = true;
|
||||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,9 +30,9 @@
|
||||||
programs.steam.extest.enable = true;
|
programs.steam.extest.enable = true;
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
|
desktopManager.gnome.enable = true;
|
||||||
keyd.enable = lib.mkForce false;
|
keyd.enable = lib.mkForce false;
|
||||||
tlp.enable = lib.mkForce false;
|
tlp.enable = lib.mkForce false;
|
||||||
desktopManager.gnome.enable = true;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
hardware.xone.enable = true;
|
hardware.xone.enable = true;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}".home = {
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
guifull.enable = true;
|
guifull.enable = true;
|
||||||
school.enable = true;
|
school.enable = true;
|
||||||
enableNixpkgsReleaseCheck = false;
|
enableNixpkgsReleaseCheck = false;
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
tags = [ "server" ];
|
|
||||||
targetHost = "53f:dc2d:80c9:3ca2:4b15:ef4d:38a0:c868";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -10,13 +9,17 @@
|
||||||
../../modules/system
|
../../modules/system
|
||||||
];
|
];
|
||||||
|
|
||||||
networking.hostId = "8745e22e";
|
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
server.enable = true;
|
nixos.tags = [
|
||||||
extraUsers.enable = true;
|
"extra-users"
|
||||||
|
"server"
|
||||||
|
];
|
||||||
stateVersion = "24.11";
|
stateVersion = "24.11";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "53f:dc2d:80c9:3ca2:4b15:ef4d:38a0:c868";
|
||||||
|
|
||||||
|
networking.hostId = "8745e22e";
|
||||||
|
|
||||||
services.nfs.server.enable = true;
|
services.nfs.server.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, nodes, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
fileSystems = with config.sysusers; with nodes; {
|
fileSystems = {
|
||||||
"/persist/storage" = {
|
"/persist/storage" = {
|
||||||
device = "/dev/disk/by-uuid/edd3e293-1aff-4fc0-96fa-4e17d6cccfca";
|
device = "/dev/disk/by-uuid/edd3e293-1aff-4fc0-96fa-4e17d6cccfca";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
|
@ -11,23 +11,7 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
# Network mounts
|
# Network mounts
|
||||||
"/home/${main}/Network/Midas" = {
|
"midas".enable = true;
|
||||||
device = "[${midas.config.deployment.targetHost}]:/storage";
|
"prophet".enable = true;
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Prophet" = {
|
|
||||||
device = "[${prophet.config.deployment.targetHost}]:/storage";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
boot.initrd = {
|
boot.initrd = {
|
||||||
availableKernelModules = [
|
availableKernelModules = [
|
||||||
|
@ -9,6 +9,7 @@
|
||||||
kernelModules = [ "dm-snapshot" ];
|
kernelModules = [ "dm-snapshot" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}".home = {
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
stateVersion = lib.mkForce config.system.stateVersion;
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
tags = [ "server" ];
|
|
||||||
targetHost = "538:e163:87ba:f847:3646:18b6:6b01:d8f8";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -12,10 +11,10 @@
|
||||||
../../modules/system
|
../../modules/system
|
||||||
];
|
];
|
||||||
|
|
||||||
networking.hostId = "38ba3f57";
|
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
server.enable = true;
|
nixos.tags = [ "server" ];
|
||||||
stateVersion = "24.11";
|
stateVersion = "24.11";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "538:e163:87ba:f847:3646:18b6:6b01:d8f8";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, nodes, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
fileSystems = with config.sysusers; with nodes; {
|
fileSystems = {
|
||||||
"/persist" = {
|
"/persist" = {
|
||||||
device = "/dev/disk/by-uuid/acf95700-8669-45c7-9a72-bf3215b3c325";
|
device = "/dev/disk/by-uuid/acf95700-8669-45c7-9a72-bf3215b3c325";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
|
@ -10,14 +10,9 @@
|
||||||
"subvol=persist"
|
"subvol=persist"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
"/kitty" = {
|
|
||||||
device = "[${kitty.config.deployment.targetHost}]:/storage/${main}";
|
# Network mounts
|
||||||
fsType = "nfs4";
|
"kitty".enable = true;
|
||||||
options = [
|
"prophet".enable = true;
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
boot.initrd = {
|
boot.initrd = {
|
||||||
availableKernelModules = [
|
availableKernelModules = [
|
||||||
|
@ -10,6 +10,7 @@
|
||||||
kernelModules = [ "dm-snapshot" ];
|
kernelModules = [ "dm-snapshot" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,5 +9,6 @@
|
||||||
address = "10.1.0.1";
|
address = "10.1.0.1";
|
||||||
interface = "enp0s31f6";
|
interface = "enp0s31f6";
|
||||||
};
|
};
|
||||||
|
hostId = "38ba3f57";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,21 +1,20 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
|
imports = [ ./nginx ];
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
cloudflare-dyndns.enable = true;
|
cloudflare-dyndns.enable = true;
|
||||||
forgejo.enable = true;
|
forgejo.enable = true;
|
||||||
icecast.enable = true;
|
icecast.enable = true;
|
||||||
jellyfin.enable = true;
|
jellyfin.enable = true;
|
||||||
lemmy.enable = true;
|
|
||||||
mastodon.enable = true;
|
mastodon.enable = true;
|
||||||
matrix-synapse.enable = true;
|
matrix-synapse.enable = true;
|
||||||
mysql.enable = true;
|
mysql.enable = true;
|
||||||
nextcloud.enable = true;
|
nextcloud.enable = true;
|
||||||
nfs.server.enable = true;
|
nfs.server.enable = true;
|
||||||
nginx.enable = true;
|
|
||||||
owncast.enable = true;
|
owncast.enable = true;
|
||||||
transmission.enable = true;
|
transmission.enable = true;
|
||||||
vaultwarden.enable = true;
|
vaultwarden.enable = true;
|
||||||
webserver.enable = true;
|
|
||||||
|
|
||||||
minecraft-servers = {
|
minecraft-servers = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
6
hosts/midas/services/nginx/default.nix
Normal file
6
hosts/midas/services/nginx/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
imports = [ ./nixfox ];
|
||||||
|
|
||||||
|
services.nginx.enable = true;
|
||||||
|
}
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
services.nginx.virtualHosts = lib.mkIf config.services.webserver.enable {
|
services.nginx.virtualHosts = {
|
||||||
"www.nixfox.ca" = {
|
"www.nixfox.ca" = {
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
addSSL = true;
|
addSSL = true;
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}".home = {
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
stateVersion = lib.mkForce config.system.stateVersion;
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
deployment = {
|
|
||||||
buildOnTarget = true;
|
|
||||||
tags = [ "server" ];
|
|
||||||
targetHost = "42f:2737:2aed:4dee:cbe4:3c73:1918:ad9b";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -12,10 +11,15 @@
|
||||||
(modulesPath + "/profiles/headless.nix")
|
(modulesPath + "/profiles/headless.nix")
|
||||||
];
|
];
|
||||||
|
|
||||||
networking.hostId = "97a21a38";
|
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
server.enable = true;
|
nixos.tags = [ "server" ];
|
||||||
stateVersion = "24.05";
|
stateVersion = "24.05";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment = {
|
||||||
|
buildOnTarget = true;
|
||||||
|
targetHost = "42f:2737:2aed:4dee:cbe4:3c73:1918:ad9b";
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.hostId = "97a21a38";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,17 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
fileSystems."/persist/storage" = {
|
fileSystems = {
|
||||||
device = "/dev/disk/by-uuid/ef465845-cc56-4db5-9260-8ae515eb025e";
|
"/persist/storage" = {
|
||||||
fsType = "btrfs";
|
device = "/dev/disk/by-uuid/ef465845-cc56-4db5-9260-8ae515eb025e";
|
||||||
options = [
|
fsType = "btrfs";
|
||||||
"nofail"
|
options = [
|
||||||
"nosuid"
|
"nofail"
|
||||||
];
|
"nosuid"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# Network mounts
|
||||||
|
"kitty".enable = true;
|
||||||
|
"midas".enable = true;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
boot.initrd = {
|
boot.initrd = {
|
||||||
availableKernelModules = [
|
availableKernelModules = [
|
||||||
|
@ -8,5 +8,5 @@
|
||||||
kernelModules = [ "dm-snapshot" ];
|
kernelModules = [ "dm-snapshot" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
|
nixpkgs.hostPlatform = "aarch64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,9 +2,10 @@
|
||||||
{
|
{
|
||||||
services = {
|
services = {
|
||||||
cloudflare-dyndns.enable = true;
|
cloudflare-dyndns.enable = true;
|
||||||
mailserver.enable = true;
|
|
||||||
mysql.enable = true;
|
mysql.enable = true;
|
||||||
nfs.server.enable = true;
|
nfs.server.enable = true;
|
||||||
nginx.enable = true;
|
nginx.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
mailserver.enable = true;
|
||||||
}
|
}
|
||||||
|
|
6
hosts/prophet/user/@!
Normal file
6
hosts/prophet/user/@!
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
{
|
||||||
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}".home = {
|
home-manager.users."${config.vars.mainUser}".home = {
|
||||||
stateVersion = lib.mkForce config.system.stateVersion;
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,17 +1,11 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
let
|
let
|
||||||
commonKernelParams = [
|
commonKernelParams = [
|
||||||
# VM/GPU passthrough
|
|
||||||
"amd_iommu=on"
|
"amd_iommu=on"
|
||||||
"iommu=pt"
|
"iommu=pt"
|
||||||
|
|
||||||
# Isolate devices into IOMMU groups
|
|
||||||
"pcie_acs_override=downstream,multifunction"
|
|
||||||
"pci=routeirq"
|
|
||||||
];
|
];
|
||||||
in {
|
in {
|
||||||
boot = {
|
boot = {
|
||||||
# Latest kernel and IOMMU isolation
|
|
||||||
kernelPackages = pkgs.linuxPackages_6_14;
|
kernelPackages = pkgs.linuxPackages_6_14;
|
||||||
kernelParams = commonKernelParams ++ [ "vfio-pci.ids=10de:1f82,10de:10fa" ];
|
kernelParams = commonKernelParams ++ [ "vfio-pci.ids=10de:1f82,10de:10fa" ];
|
||||||
|
|
||||||
|
@ -30,8 +24,5 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
# Use second GPU on boot
|
# Use second GPU on boot
|
||||||
specialisation.gputwo.configuration = {
|
specialisation.gputwo.configuration.boot.kernelParams = commonKernelParams ++ [ "vfio-pci.ids=10de:2504,10de:228e" ];
|
||||||
boot.kernelParams = commonKernelParams ++ [ "vfio-pci.ids=10de:2504,10de:228e" ];
|
|
||||||
environment.sessionVariables.WLR_RENDERER = lib.mkForce "gles2";
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
deployment = {
|
deployment = {
|
||||||
tags = [
|
tags = [
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./colmena
|
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
@ -11,10 +10,13 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
desktop.enable = true;
|
nixos.tags = [ "pc" ];
|
||||||
nvidia.enable = true;
|
|
||||||
stateVersion = "24.05";
|
stateVersion = "24.05";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deployment.targetHost = "4e4:535:9d47:f367:becd:6557:458d:5b1b";
|
||||||
|
|
||||||
|
services.xserver.videoDrivers = [ "nvidia" ];
|
||||||
|
|
||||||
virtualisation.libvirtd.enable = true;
|
virtualisation.libvirtd.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, nodes, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
fileSystems = with config.sysusers; with nodes; {
|
fileSystems = {
|
||||||
# Games and such
|
# Games and such
|
||||||
"/mnt/Linux1" = {
|
"/mnt/Linux1" = {
|
||||||
device = "/dev/disk/by-uuid/b2901f8c-ffda-4b88-bb63-a9ea0c96ccb4";
|
device = "/dev/disk/by-uuid/b2901f8c-ffda-4b88-bb63-a9ea0c96ccb4";
|
||||||
|
@ -39,32 +39,8 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
# Network mounts
|
# Network mounts
|
||||||
"/home/${main}/Network/Midas" = {
|
"kitty".enable = true;
|
||||||
device = "[${midas.config.deployment.targetHost}]:/storage";
|
"midas".enable = true;
|
||||||
fsType = "nfs4";
|
"prophet".enable = true;
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Kitty" = {
|
|
||||||
device = "[${kitty.config.deployment.targetHost}]:/storage/${main}";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"/home/${main}/Network/Prophet" = {
|
|
||||||
device = "[${prophet.config.deployment.targetHost}]:/storage";
|
|
||||||
fsType = "nfs4";
|
|
||||||
options = [
|
|
||||||
"noauto"
|
|
||||||
"soft"
|
|
||||||
"x-systemd.automount"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, modulesPath, ... }:
|
{ modulesPath, ... }:
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
||||||
kernelModules = [ "kvm-amd" ];
|
kernelModules = [ "kvm-amd" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
hardware.cpu.amd.updateMicrocode = true;
|
||||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
|
nixpkgs.hostPlatform = "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
home-manager.users."${config.sysusers.main}" = {
|
home-manager.users."${config.vars.mainUser}" = {
|
||||||
home = {
|
home = {
|
||||||
guifull.enable = true;
|
guifull.enable = true;
|
||||||
stateVersion = lib.mkForce config.system.stateVersion;
|
stateVersion = lib.mkForce config.system.stateVersion;
|
||||||
|
|
|
@ -9,5 +9,5 @@
|
||||||
./wms
|
./wms
|
||||||
];
|
];
|
||||||
|
|
||||||
config.home.stateVersion = "24.11";
|
config.home.stateVersion = "25.05";
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,11 +6,11 @@
|
||||||
settings = {
|
settings = {
|
||||||
main = {
|
main = {
|
||||||
term = "xterm-256color";
|
term = "xterm-256color";
|
||||||
font = "${config.look.fonts.mono}:size=14.7";
|
font = "${config.vars.fonts.mono}:size=14.7";
|
||||||
};
|
};
|
||||||
colors = {
|
colors = {
|
||||||
alpha = "0.85";
|
alpha = "0.85";
|
||||||
background = config.look.colors.dark;
|
background = config.vars.colors.dark;
|
||||||
regular0 = "3f3f3f";
|
regular0 = "3f3f3f";
|
||||||
regular1 = "cc0000";
|
regular1 = "cc0000";
|
||||||
regular2 = "4e9a06";
|
regular2 = "4e9a06";
|
||||||
|
@ -29,7 +29,10 @@
|
||||||
bright7 = "ffffff";
|
bright7 = "ffffff";
|
||||||
};
|
};
|
||||||
cursor.style = "beam";
|
cursor.style = "beam";
|
||||||
key-bindings.search-start = "Control+f";
|
key-bindings = {
|
||||||
|
search-start = "Control+f";
|
||||||
|
show-urls-launch = "Control+s";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -146,9 +146,9 @@
|
||||||
"webgl.disabled" = false;
|
"webgl.disabled" = false;
|
||||||
|
|
||||||
# Fonts
|
# Fonts
|
||||||
"font.name.monospace.x-western" = config.look.fonts.mono;
|
"font.name.monospace.x-western" = config.vars.fonts.mono;
|
||||||
"font.name.sans-serif.x-western" = config.look.fonts.main;
|
"font.name.sans-serif.x-western" = config.vars.fonts.main;
|
||||||
"font.name.serif.x-western" = config.look.fonts.main;
|
"font.name.serif.x-western" = config.vars.fonts.main;
|
||||||
|
|
||||||
# Theming and visibility
|
# Theming and visibility
|
||||||
"browser.aboutConfig.showWarning" = false;
|
"browser.aboutConfig.showWarning" = false;
|
||||||
|
@ -235,16 +235,16 @@
|
||||||
|
|
||||||
userChrome = ''
|
userChrome = ''
|
||||||
:root {
|
:root {
|
||||||
--tab-active-bg-color: #${config.look.colors.prime};
|
--tab-active-bg-color: #${config.vars.colors.prime};
|
||||||
--tab-hover-bg-color: #${config.look.colors.accent};
|
--tab-hover-bg-color: #${config.vars.colors.accent};
|
||||||
--tab-inactive-bg-color: #${config.look.colors.dark};
|
--tab-inactive-bg-color: #${config.vars.colors.dark};
|
||||||
--tab-active-fg-fallback-color: #FFFFFF;
|
--tab-active-fg-fallback-color: #FFFFFF;
|
||||||
--tab-inactive-fg-fallback-color: #${config.look.colors.text};
|
--tab-inactive-fg-fallback-color: #${config.vars.colors.text};
|
||||||
--urlbar-focused-bg-color: #${config.look.colors.dark};
|
--urlbar-focused-bg-color: #${config.vars.colors.dark};
|
||||||
--urlbar-not-focused-bg-color: #${config.look.colors.dark};
|
--urlbar-not-focused-bg-color: #${config.vars.colors.dark};
|
||||||
--toolbar-bgcolor: #${config.look.colors.dark} !important;
|
--toolbar-bgcolor: #${config.vars.colors.dark} !important;
|
||||||
--tab-font: '${config.look.fonts.main}';
|
--tab-font: '${config.vars.fonts.main}';
|
||||||
--urlbar-font: '${config.look.fonts.main}';
|
--urlbar-font: '${config.vars.fonts.main}';
|
||||||
${builtins.readFile ./quteFox.css}
|
${builtins.readFile ./quteFox.css}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
|
@ -92,8 +92,8 @@
|
||||||
let g:airline_theme='onedark'
|
let g:airline_theme='onedark'
|
||||||
let g:airline#extensions#tabline#enabled = 1
|
let g:airline#extensions#tabline#enabled = 1
|
||||||
hi Normal guibg=none
|
hi Normal guibg=none
|
||||||
hi Visual guibg=#${config.look.colors.mid}
|
hi Visual guibg=#${config.vars.colors.mid}
|
||||||
hi Pmenu guibg=#${config.look.colors.mid}
|
hi Pmenu guibg=#${config.vars.colors.mid}
|
||||||
hi EndOfBuffer guibg=none
|
hi EndOfBuffer guibg=none
|
||||||
hi LineNr guibg=none
|
hi LineNr guibg=none
|
||||||
lua require'colorizer'.setup()
|
lua require'colorizer'.setup()
|
||||||
|
|
|
@ -3,8 +3,8 @@
|
||||||
fonts.fontconfig = {
|
fonts.fontconfig = {
|
||||||
enable = config.home.desktop.enable;
|
enable = config.home.desktop.enable;
|
||||||
defaultFonts = {
|
defaultFonts = {
|
||||||
sansSerif = [ config.look.fonts.main ];
|
sansSerif = [ config.vars.fonts.main ];
|
||||||
monospace = [ config.look.fonts.mono ];
|
monospace = [ config.vars.fonts.mono ];
|
||||||
emoji = [ "Twitter Color Emoji" ];
|
emoji = [ "Twitter Color Emoji" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
{
|
{
|
||||||
gtk = with pkgs; {
|
gtk = with pkgs; {
|
||||||
font = {
|
font = {
|
||||||
name = config.look.fonts.main;
|
name = config.vars.fonts.main;
|
||||||
size = 11;
|
size = 11;
|
||||||
};
|
};
|
||||||
theme = {
|
theme = {
|
||||||
|
@ -21,7 +21,7 @@
|
||||||
iconTheme = {
|
iconTheme = {
|
||||||
name = "Papirus-Dark";
|
name = "Papirus-Dark";
|
||||||
package = papirus-icon-theme.override {
|
package = papirus-icon-theme.override {
|
||||||
color = config.look.colors.folder;
|
color = config.vars.colors.folder;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,9 +1,6 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [ ./dirs ];
|
||||||
./defaults
|
|
||||||
./folders
|
|
||||||
];
|
|
||||||
|
|
||||||
xdg.enable = config.home.desktop.enable;
|
xdg.enable = config.home.desktop.enable;
|
||||||
|
|
||||||
|
|
|
@ -1,21 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
xdg.mimeApps = {
|
|
||||||
enable = config.xdg.enable;
|
|
||||||
defaultApplications = {
|
|
||||||
# Media
|
|
||||||
"image/*" = [ "imv.desktop" ];
|
|
||||||
"image/gif" = [ "mpv.desktop" ];
|
|
||||||
"video/*" = [ "mpv.desktop" ];
|
|
||||||
|
|
||||||
# Apps
|
|
||||||
"inode/directory" = [ "pcmanfm-qt.desktop" ];
|
|
||||||
"text/plain" = [ "nvim.desktop" ];
|
|
||||||
|
|
||||||
# Browser
|
|
||||||
"application/x-mswinurl" = [ "librewolf.desktop" ];
|
|
||||||
"x-scheme-handler/http" = [ "librewolf.desktop" ];
|
|
||||||
"x-scheme-handler/https" = [ "librewolf.desktop" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -13,7 +13,7 @@
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
XDG_GAMES_DIR = "${homeDirectory}/Games";
|
XDG_GAMES_DIR = "${homeDirectory}/Games";
|
||||||
XDG_KEEPERS_DIR = "${homeDirectory}/Keepers";
|
XDG_KEEPERS_DIR = "${homeDirectory}/Keepers";
|
||||||
XDG_NETWORK_DIR = "${homeDirectory}/Network";
|
XDG_NETWORK_DIR = "/network";
|
||||||
XDG_PERSIST_DIR = "/persist${homeDirectory}";
|
XDG_PERSIST_DIR = "/persist${homeDirectory}";
|
||||||
XDG_PROJECTS_DIR = "${homeDirectory}/Projects";
|
XDG_PROJECTS_DIR = "${homeDirectory}/Projects";
|
||||||
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
look.border = rec {
|
vars.border = rec {
|
||||||
int = 3;
|
int = 3;
|
||||||
string = toString int;
|
string = toString int;
|
||||||
};
|
};
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
look.colors = {
|
vars.colors = {
|
||||||
prime = "3823C4"; #3823C4
|
prime = "3823C4"; #3823C4
|
||||||
accent = "1B1F59"; #1B1F59
|
accent = "1B1F59"; #1B1F59
|
||||||
split = "555B9E"; #555B9E
|
split = "555B9E"; #555B9E
|
|
@ -1,8 +1,14 @@
|
||||||
{ ... }:
|
{ lib, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
|
./border
|
||||||
|
./colors
|
||||||
./displays
|
./displays
|
||||||
./look
|
./fonts
|
||||||
./workspaces
|
./workspaces
|
||||||
];
|
];
|
||||||
|
|
||||||
|
options.vars = lib.mkOption {
|
||||||
|
type = lib.types.attrs;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
options.displays = lib.mkOption {
|
vars.displays = {
|
||||||
type = lib.types.attrs;
|
|
||||||
};
|
|
||||||
|
|
||||||
config.displays = {
|
|
||||||
tower1 = "Microstep MSI G24C 0000000000001";
|
tower1 = "Microstep MSI G24C 0000000000001";
|
||||||
tower2 = "BNQ BenQ GW2270 6CH00781019";
|
tower2 = "BNQ BenQ GW2270 6CH00781019";
|
||||||
tower3 = "Eizo Nanao Corporation CG223W 23252050";
|
tower3 = "Eizo Nanao Corporation CG223W 23252050";
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
look.fonts = {
|
vars.fonts = {
|
||||||
main = "Ubuntu Nerd Font";
|
main = "Ubuntu Nerd Font";
|
||||||
mono = "UbuntuMono Nerd Font";
|
mono = "UbuntuMono Nerd Font";
|
||||||
};
|
};
|
|
@ -1,12 +0,0 @@
|
||||||
{ config, lib, ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./border
|
|
||||||
./colors
|
|
||||||
./fonts
|
|
||||||
];
|
|
||||||
|
|
||||||
options.look = lib.mkOption {
|
|
||||||
type = lib.types.attrs;
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,10 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
options.ws = lib.mkOption {
|
vars.ws = {
|
||||||
type = lib.types.attrs;
|
|
||||||
};
|
|
||||||
|
|
||||||
config.ws = {
|
|
||||||
w0 = "0";
|
w0 = "0";
|
||||||
w1 = "1";
|
w1 = "1";
|
||||||
w2 = "2";
|
w2 = "2";
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
{
|
{
|
||||||
services.kanshi = {
|
services.kanshi = {
|
||||||
enable = config.home.desktop.enable;
|
enable = config.home.desktop.enable;
|
||||||
settings = [
|
settings = with config.vars.displays; [
|
||||||
# Outputs
|
# Outputs
|
||||||
{
|
{
|
||||||
output = {
|
output = {
|
||||||
criteria = config.displays.tower1;
|
criteria = tower1;
|
||||||
adaptiveSync = true;
|
adaptiveSync = true;
|
||||||
mode = "1920x1080@143.979996Hz";
|
mode = "1920x1080@143.979996Hz";
|
||||||
};
|
};
|
||||||
|
@ -18,20 +18,20 @@
|
||||||
name = "tower-tv";
|
name = "tower-tv";
|
||||||
outputs = [
|
outputs = [
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower1;
|
criteria = tower1;
|
||||||
position = "3840,405";
|
position = "3840,405";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower2;
|
criteria = tower2;
|
||||||
position = "1920,405";
|
position = "1920,405";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower3;
|
criteria = tower3;
|
||||||
position = "5760,0";
|
position = "5760,0";
|
||||||
transform = "90";
|
transform = "90";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower4;
|
criteria = tower4;
|
||||||
position = "0,405";
|
position = "0,405";
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
@ -42,15 +42,15 @@
|
||||||
name = "tower";
|
name = "tower";
|
||||||
outputs = [
|
outputs = [
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower1;
|
criteria = tower1;
|
||||||
position = "1920,405";
|
position = "1920,405";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower2;
|
criteria = tower2;
|
||||||
position = "0,405";
|
position = "0,405";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = config.displays.tower3;
|
criteria = tower3;
|
||||||
position = "3840,0";
|
position = "3840,0";
|
||||||
transform = "90";
|
transform = "90";
|
||||||
}
|
}
|
||||||
|
@ -63,11 +63,11 @@
|
||||||
name = "detritus";
|
name = "detritus";
|
||||||
outputs = [
|
outputs = [
|
||||||
{
|
{
|
||||||
criteria = config.displays.detritus1;
|
criteria = detritus1;
|
||||||
position = "0,0";
|
position = "0,0";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = config.displays.detritus2;
|
criteria = detritus2;
|
||||||
position = "1920,0";
|
position = "1920,0";
|
||||||
scale = 0.85;
|
scale = 0.85;
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,10 +4,10 @@
|
||||||
enable = config.home.desktop.enable;
|
enable = config.home.desktop.enable;
|
||||||
settings = {
|
settings = {
|
||||||
# Theme
|
# Theme
|
||||||
background-color = "#${config.look.colors.dark}D9";
|
background-color = "#${config.vars.colors.dark}D9";
|
||||||
border-color = "#${config.look.colors.accent}";
|
border-color = "#${config.vars.colors.accent}";
|
||||||
border-size = config.look.border.int;
|
border-size = config.vars.border.int;
|
||||||
font = "${config.look.fonts.main} 12";
|
font = "${config.vars.fonts.main} 12";
|
||||||
margin = 0;
|
margin = 0;
|
||||||
max-icon-size = 40;
|
max-icon-size = 40;
|
||||||
outer-margin = 10;
|
outer-margin = 10;
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.rofi-wayland;
|
package = pkgs.rofi-wayland;
|
||||||
terminal = "foot";
|
terminal = "foot";
|
||||||
font = "${config.look.fonts.main} 14";
|
font = "${config.vars.fonts.main} 14";
|
||||||
theme = let
|
theme = let
|
||||||
inherit (config.lib.formats.rasi) mkLiteral;
|
inherit (config.lib.formats.rasi) mkLiteral;
|
||||||
in {
|
in {
|
||||||
|
@ -18,24 +18,24 @@
|
||||||
red = mkLiteral "#DC322F";
|
red = mkLiteral "#DC322F";
|
||||||
background-color = mkLiteral "#00000000";
|
background-color = mkLiteral "#00000000";
|
||||||
separatorcolor = mkLiteral "#00000000";
|
separatorcolor = mkLiteral "#00000000";
|
||||||
normal-foreground = mkLiteral "#${config.look.colors.text}";
|
normal-foreground = mkLiteral "#${config.vars.colors.text}";
|
||||||
normal-background = mkLiteral "#${config.look.colors.dark}1A";
|
normal-background = mkLiteral "#${config.vars.colors.dark}1A";
|
||||||
urgent-foreground = mkLiteral "#${config.look.colors.urgent}";
|
urgent-foreground = mkLiteral "#${config.vars.colors.urgent}";
|
||||||
active-foreground = mkLiteral "#${config.look.colors.split}";
|
active-foreground = mkLiteral "#${config.vars.colors.split}";
|
||||||
selected-active-foreground = mkLiteral "#${config.look.colors.prime}";
|
selected-active-foreground = mkLiteral "#${config.vars.colors.prime}";
|
||||||
background = mkLiteral "#${config.look.colors.dark}D9";
|
background = mkLiteral "#${config.vars.colors.dark}D9";
|
||||||
bordercolor = mkLiteral "#${config.look.colors.prime}";
|
bordercolor = mkLiteral "#${config.vars.colors.prime}";
|
||||||
selected-normal-foreground = mkLiteral "#FFFFFF";
|
selected-normal-foreground = mkLiteral "#FFFFFF";
|
||||||
selected-normal-background = mkLiteral "#${config.look.colors.prime}80";
|
selected-normal-background = mkLiteral "#${config.vars.colors.prime}80";
|
||||||
border-color = mkLiteral "#${config.look.colors.prime}";
|
border-color = mkLiteral "#${config.vars.colors.prime}";
|
||||||
urgent-background = mkLiteral "#${config.look.colors.accent}26";
|
urgent-background = mkLiteral "#${config.vars.colors.accent}26";
|
||||||
active-background = mkLiteral "#${config.look.colors.accent}26";
|
active-background = mkLiteral "#${config.vars.colors.accent}26";
|
||||||
selected-active-background = mkLiteral "#${config.look.colors.split}54";
|
selected-active-background = mkLiteral "#${config.vars.colors.split}54";
|
||||||
};
|
};
|
||||||
"#window" = {
|
"#window" = {
|
||||||
background-color = mkLiteral "@background";
|
background-color = mkLiteral "@background";
|
||||||
width = 500;
|
width = 500;
|
||||||
border = mkLiteral "${config.look.border.string}";
|
border = mkLiteral "${config.vars.border.string}";
|
||||||
padding = 5;
|
padding = 5;
|
||||||
};
|
};
|
||||||
"#message" = {
|
"#message" = {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
let
|
||||||
default = "#${config.look.colors.prime}FF";
|
default = "#${config.vars.colors.prime}FF";
|
||||||
wrong = "#${config.look.colors.split}FF";
|
wrong = "#${config.vars.colors.split}FF";
|
||||||
verifying = "#${config.look.colors.accent}FF";
|
verifying = "#${config.vars.colors.accent}FF";
|
||||||
blank = "#00000000";
|
blank = "#00000000";
|
||||||
clear = "#FFFFFF22";
|
clear = "#FFFFFF22";
|
||||||
text = "#FFFFFFFF";
|
text = "#FFFFFFFF";
|
||||||
|
@ -13,7 +13,7 @@ in {
|
||||||
settings = {
|
settings = {
|
||||||
clock = true;
|
clock = true;
|
||||||
image = ".wallpapers/lock.png";
|
image = ".wallpapers/lock.png";
|
||||||
font = config.look.fonts.main;
|
font = config.vars.fonts.main;
|
||||||
font-size = 30;
|
font-size = 30;
|
||||||
timestr = "%I:%M%p";
|
timestr = "%I:%M%p";
|
||||||
datestr = "%a %b %d %Y";
|
datestr = "%a %b %d %Y";
|
||||||
|
|
|
@ -5,8 +5,8 @@
|
||||||
settings = {
|
settings = {
|
||||||
default.mode = "center";
|
default.mode = "center";
|
||||||
any.path = ".wallpapers/1.png";
|
any.path = ".wallpapers/1.png";
|
||||||
"${config.displays.tower2}".path = ".wallpapers/2.png";
|
"${config.vars.displays.tower2}".path = ".wallpapers/2.png";
|
||||||
"${config.displays.tower3}".path = ".wallpapers/3.png";
|
"${config.vars.displays.tower3}".path = ".wallpapers/3.png";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -236,9 +236,9 @@
|
||||||
position = "top";
|
position = "top";
|
||||||
layer = "top";
|
layer = "top";
|
||||||
output = [
|
output = [
|
||||||
"!${config.displays.tower2}"
|
"!${config.vars.displays.tower2}"
|
||||||
"!${config.displays.tower3}"
|
"!${config.vars.displays.tower3}"
|
||||||
"!${config.displays.detritus2}"
|
"!${config.vars.displays.detritus2}"
|
||||||
"*"
|
"*"
|
||||||
];
|
];
|
||||||
modules-left = [
|
modules-left = [
|
||||||
|
@ -271,9 +271,9 @@
|
||||||
position = "top";
|
position = "top";
|
||||||
layer = "top";
|
layer = "top";
|
||||||
output = [
|
output = [
|
||||||
config.displays.tower2
|
config.vars.displays.tower2
|
||||||
config.displays.tower3
|
config.vars.displays.tower3
|
||||||
config.displays.detritus2
|
config.vars.displays.detritus2
|
||||||
];
|
];
|
||||||
modules-left = [
|
modules-left = [
|
||||||
"sway/workspaces"
|
"sway/workspaces"
|
||||||
|
@ -294,12 +294,11 @@
|
||||||
border: 0;
|
border: 0;
|
||||||
border-radius: 0;
|
border-radius: 0;
|
||||||
min-height: 0;
|
min-height: 0;
|
||||||
font-family: ${config.look.fonts.main};
|
|
||||||
font-size: 15.5px;
|
font-size: 15.5px;
|
||||||
color: #${config.look.colors.text};
|
color: #${config.vars.colors.text};
|
||||||
}
|
}
|
||||||
|
|
||||||
#waybar { background: #${config.look.colors.dark}; }
|
#waybar { background: #${config.vars.colors.dark}; }
|
||||||
#network { padding: 0 6px 0 4px; }
|
#network { padding: 0 6px 0 4px; }
|
||||||
#gamemode, #scratchpad, #privacy, #tray, #bluetooth { margin: 0 2px 0 2px; }
|
#gamemode, #scratchpad, #privacy, #tray, #bluetooth { margin: 0 2px 0 2px; }
|
||||||
#pulseaudio, #mpris, #custom-notifs, #idle_inhibitor, #custom-weather, #cpu, #memory, #custom-vram, #backlight, #battery, #clock { margin: 0 2px 0 4px; }
|
#pulseaudio, #mpris, #custom-notifs, #idle_inhibitor, #custom-weather, #cpu, #memory, #custom-vram, #backlight, #battery, #clock { margin: 0 2px 0 4px; }
|
||||||
|
@ -312,15 +311,15 @@
|
||||||
min-width: 20px;
|
min-width: 20px;
|
||||||
}
|
}
|
||||||
#workspaces button.visible, #workspaces button.active {
|
#workspaces button.visible, #workspaces button.active {
|
||||||
border-bottom: 3px solid #${config.look.colors.prime};
|
border-bottom: 3px solid #${config.vars.colors.prime};
|
||||||
background: #${config.look.colors.mid};
|
background: #${config.vars.colors.mid};
|
||||||
}
|
}
|
||||||
#workspaces button.urgent {
|
#workspaces button.urgent {
|
||||||
border-bottom: 3px solid #${config.look.colors.urgent};
|
border-bottom: 3px solid #${config.vars.colors.urgent};
|
||||||
}
|
}
|
||||||
#workspaces button:hover {
|
#workspaces button:hover {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
background: #${config.look.colors.light};
|
background: #${config.vars.colors.light};
|
||||||
}
|
}
|
||||||
|
|
||||||
#mpris { border-bottom: 3px solid #ffb066; }
|
#mpris { border-bottom: 3px solid #ffb066; }
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
in {
|
in {
|
||||||
# Hotkeys
|
# Hotkeys
|
||||||
modifier = "${primeMod}";
|
modifier = "${primeMod}";
|
||||||
keybindings = {
|
keybindings = with config.vars.ws; {
|
||||||
## Launchers
|
## Launchers
|
||||||
|
|
||||||
# Browser
|
# Browser
|
||||||
|
@ -78,50 +78,50 @@
|
||||||
"${primeMod}+Shift+r" = ''reload'';
|
"${primeMod}+Shift+r" = ''reload'';
|
||||||
|
|
||||||
# Switch to workspaces
|
# Switch to workspaces
|
||||||
"${primeMod}+grave" = ''workspace 0:${config.ws.w0}'';
|
"${primeMod}+grave" = ''workspace 0:${w0}'';
|
||||||
"${primeMod}+1" = ''workspace 1:${config.ws.w1}'';
|
"${primeMod}+1" = ''workspace 1:${w1}'';
|
||||||
"${primeMod}+2" = ''workspace 2:${config.ws.w2}'';
|
"${primeMod}+2" = ''workspace 2:${w2}'';
|
||||||
"${primeMod}+3" = ''workspace 3:${config.ws.w3}'';
|
"${primeMod}+3" = ''workspace 3:${w3}'';
|
||||||
"${primeMod}+4" = ''workspace 4:${config.ws.w4}'';
|
"${primeMod}+4" = ''workspace 4:${w4}'';
|
||||||
"${primeMod}+5" = ''workspace 5:${config.ws.w5}'';
|
"${primeMod}+5" = ''workspace 5:${w5}'';
|
||||||
"${primeMod}+6" = ''workspace 6:${config.ws.w6}'';
|
"${primeMod}+6" = ''workspace 6:${w6}'';
|
||||||
"${primeMod}+7" = ''workspace 7:${config.ws.w7}'';
|
"${primeMod}+7" = ''workspace 7:${w7}'';
|
||||||
"${primeMod}+8" = ''workspace 8:${config.ws.w8}'';
|
"${primeMod}+8" = ''workspace 8:${w8}'';
|
||||||
"${primeMod}+9" = ''workspace 9:${config.ws.w9}'';
|
"${primeMod}+9" = ''workspace 9:${w9}'';
|
||||||
|
|
||||||
# Switch to alternate workspaces
|
# Switch to alternate workspaces
|
||||||
"${secMod}+F1" = ''workspace 11:${config.ws.w1a}'';
|
"${secMod}+F1" = ''workspace 11:${w1a}'';
|
||||||
"${secMod}+F2" = ''workspace 22:${config.ws.w2a}'';
|
"${secMod}+F2" = ''workspace 22:${w2a}'';
|
||||||
"${secMod}+F3" = ''workspace 33:${config.ws.w3a}'';
|
"${secMod}+F3" = ''workspace 33:${w3a}'';
|
||||||
"${secMod}+F4" = ''workspace 44:${config.ws.w4a}'';
|
"${secMod}+F4" = ''workspace 44:${w4a}'';
|
||||||
"${secMod}+F5" = ''workspace 55:${config.ws.w5a}'';
|
"${secMod}+F5" = ''workspace 55:${w5a}'';
|
||||||
"${secMod}+F6" = ''workspace 66:${config.ws.w6a}'';
|
"${secMod}+F6" = ''workspace 66:${w6a}'';
|
||||||
"${secMod}+F7" = ''workspace 77:${config.ws.w7a}'';
|
"${secMod}+F7" = ''workspace 77:${w7a}'';
|
||||||
"${secMod}+F8" = ''workspace 88:${config.ws.w8a}'';
|
"${secMod}+F8" = ''workspace 88:${w8a}'';
|
||||||
"${secMod}+F9" = ''workspace 99:${config.ws.w9a}'';
|
"${secMod}+F9" = ''workspace 99:${w9a}'';
|
||||||
|
|
||||||
# Move window to and focus workspace
|
# Move window to and focus workspace
|
||||||
"${primeMod}+Shift+grave" = ''move container to workspace 0:${config.ws.w0}; workspace 0:${config.ws.w0}'';
|
"${primeMod}+Shift+grave" = ''move container to workspace 0:${w0}; workspace 0:${w0}'';
|
||||||
"${primeMod}+Shift+1" = ''move container to workspace 1:${config.ws.w1}; workspace 1:${config.ws.w1}'';
|
"${primeMod}+Shift+1" = ''move container to workspace 1:${w1}; workspace 1:${w1}'';
|
||||||
"${primeMod}+Shift+2" = ''move container to workspace 2:${config.ws.w2}; workspace 2:${config.ws.w2}'';
|
"${primeMod}+Shift+2" = ''move container to workspace 2:${w2}; workspace 2:${w2}'';
|
||||||
"${primeMod}+Shift+3" = ''move container to workspace 3:${config.ws.w3}; workspace 3:${config.ws.w3}'';
|
"${primeMod}+Shift+3" = ''move container to workspace 3:${w3}; workspace 3:${w3}'';
|
||||||
"${primeMod}+Shift+4" = ''move container to workspace 4:${config.ws.w4}; workspace 4:${config.ws.w4}'';
|
"${primeMod}+Shift+4" = ''move container to workspace 4:${w4}; workspace 4:${w4}'';
|
||||||
"${primeMod}+Shift+5" = ''move container to workspace 5:${config.ws.w5}; workspace 5:${config.ws.w5}'';
|
"${primeMod}+Shift+5" = ''move container to workspace 5:${w5}; workspace 5:${w5}'';
|
||||||
"${primeMod}+Shift+6" = ''move container to workspace 6:${config.ws.w6}; workspace 6:${config.ws.w6}'';
|
"${primeMod}+Shift+6" = ''move container to workspace 6:${w6}; workspace 6:${w6}'';
|
||||||
"${primeMod}+Shift+7" = ''move container to workspace 7:${config.ws.w7}; workspace 7:${config.ws.w7}'';
|
"${primeMod}+Shift+7" = ''move container to workspace 7:${w7}; workspace 7:${w7}'';
|
||||||
"${primeMod}+Shift+8" = ''move container to workspace 8:${config.ws.w8}; workspace 8:${config.ws.w8}'';
|
"${primeMod}+Shift+8" = ''move container to workspace 8:${w8}; workspace 8:${w8}'';
|
||||||
"${primeMod}+Shift+9" = ''move container to workspace 9:${config.ws.w9}; workspace 9:${config.ws.w9}'';
|
"${primeMod}+Shift+9" = ''move container to workspace 9:${w9}; workspace 9:${w9}'';
|
||||||
|
|
||||||
# Move window to and focus alternate workspace
|
# Move window to and focus alternate workspace
|
||||||
"${secMod}+Shift+F1" = ''move container to workspace 11:${config.ws.w1a}; workspace 11:${config.ws.w1a}'';
|
"${secMod}+Shift+F1" = ''move container to workspace 11:${w1a}; workspace 11:${w1a}'';
|
||||||
"${secMod}+Shift+F2" = ''move container to workspace 22:${config.ws.w2a}; workspace 22:${config.ws.w2a}'';
|
"${secMod}+Shift+F2" = ''move container to workspace 22:${w2a}; workspace 22:${w2a}'';
|
||||||
"${secMod}+Shift+F3" = ''move container to workspace 33:${config.ws.w3a}; workspace 33:${config.ws.w3a}'';
|
"${secMod}+Shift+F3" = ''move container to workspace 33:${w3a}; workspace 33:${w3a}'';
|
||||||
"${secMod}+Shift+F4" = ''move container to workspace 44:${config.ws.w4a}; workspace 44:${config.ws.w4a}'';
|
"${secMod}+Shift+F4" = ''move container to workspace 44:${w4a}; workspace 44:${w4a}'';
|
||||||
"${secMod}+Shift+F5" = ''move container to workspace 55:${config.ws.w5a}; workspace 55:${config.ws.w5a}'';
|
"${secMod}+Shift+F5" = ''move container to workspace 55:${w5a}; workspace 55:${w5a}'';
|
||||||
"${secMod}+Shift+F6" = ''move container to workspace 66:${config.ws.w6a}; workspace 66:${config.ws.w6a}'';
|
"${secMod}+Shift+F6" = ''move container to workspace 66:${w6a}; workspace 66:${w6a}'';
|
||||||
"${secMod}+Shift+F7" = ''move container to workspace 77:${config.ws.w7a}; workspace 77:${config.ws.w7a}'';
|
"${secMod}+Shift+F7" = ''move container to workspace 77:${w7a}; workspace 77:${w7a}'';
|
||||||
"${secMod}+Shift+F8" = ''move container to workspace 88:${config.ws.w8a}; workspace 88:${config.ws.w8a}'';
|
"${secMod}+Shift+F8" = ''move container to workspace 88:${w8a}; workspace 88:${w8a}'';
|
||||||
"${secMod}+Shift+F9" = ''move container to workspace 99:${config.ws.w9a}; workspace 99:${config.ws.w9a}'';
|
"${secMod}+Shift+F9" = ''move container to workspace 99:${w9a}; workspace 99:${w9a}'';
|
||||||
|
|
||||||
# Change focused window
|
# Change focused window
|
||||||
"${primeMod}+h" = ''focus left'';
|
"${primeMod}+h" = ''focus left'';
|
||||||
|
|
|
@ -2,47 +2,42 @@
|
||||||
{
|
{
|
||||||
# Monitors
|
# Monitors
|
||||||
wayland.windowManager.sway.config = {
|
wayland.windowManager.sway.config = {
|
||||||
workspaceOutputAssign = let
|
workspaceOutputAssign = with config.vars.ws; with config.vars.displays; let
|
||||||
workspaces1 = [
|
workspaces1 = [
|
||||||
"0:${config.ws.w0}"
|
"0:${w0}"
|
||||||
"1:${config.ws.w1}"
|
"1:${w1}"
|
||||||
"2:${config.ws.w2}"
|
"2:${w2}"
|
||||||
"3:${config.ws.w3}"
|
"3:${w3}"
|
||||||
"11:${config.ws.w1a}"
|
"11:${w1a}"
|
||||||
"22:${config.ws.w2a}"
|
"22:${w2a}"
|
||||||
"33:${config.ws.w3a}"
|
"33:${w3a}"
|
||||||
];
|
];
|
||||||
workspaces2 = [
|
workspaces2 = [
|
||||||
"4:${config.ws.w4}"
|
"4:${w4}"
|
||||||
"5:${config.ws.w5}"
|
"5:${w5}"
|
||||||
"6:${config.ws.w6}"
|
"6:${w6}"
|
||||||
"44:${config.ws.w4a}"
|
"44:${w4a}"
|
||||||
"55:${config.ws.w5a}"
|
"55:${w5a}"
|
||||||
];
|
];
|
||||||
workspaces3 = [
|
workspaces3 = [
|
||||||
"7:${config.ws.w7}"
|
"7:${w7}"
|
||||||
"8:${config.ws.w8}"
|
"8:${w8}"
|
||||||
"9:${config.ws.w9}"
|
"9:${w9}"
|
||||||
"77:${config.ws.w7a}"
|
"77:${w7a}"
|
||||||
"88:${config.ws.w8a}"
|
"88:${w8a}"
|
||||||
];
|
];
|
||||||
workspaces4 = [
|
workspaces4 = [
|
||||||
"66:${config.ws.w6a}"
|
"66:${w6a}"
|
||||||
"99:${config.ws.w9a}"
|
"99:${w9a}"
|
||||||
];
|
];
|
||||||
assign = output: workspaces: map (workspace: {
|
assign = output: workspaces: map (workspace: {
|
||||||
inherit workspace;
|
inherit workspace;
|
||||||
inherit output;
|
inherit output;
|
||||||
}) workspaces;
|
}) workspaces;
|
||||||
in
|
in
|
||||||
(assign "${config.displays.tower1}" workspaces1) ++
|
(assign "${tower1}" workspaces1) ++
|
||||||
(assign "${config.displays.tower2}" workspaces2) ++
|
(assign "${tower2}" workspaces2) ++
|
||||||
(assign "${config.displays.tower3}" workspaces3) ++
|
(assign "${tower3}" workspaces3) ++
|
||||||
(assign "${config.displays.tower4}" workspaces4) ++
|
(assign "${tower4}" workspaces4);
|
||||||
|
|
||||||
(assign "${config.displays.detritus1}" workspaces1) ++
|
|
||||||
(assign "${config.displays.detritus1}" workspaces2) ++
|
|
||||||
(assign "${config.displays.detritus2}" workspaces3) ++
|
|
||||||
(assign "${config.displays.detritus2}" workspaces4);
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
wayland.windowManager.sway.config = {
|
wayland.windowManager.sway.config = with config.vars.ws; {
|
||||||
defaultWorkspace = "workspace 1:${config.ws.w1}";
|
defaultWorkspace = "workspace 1:${w1}";
|
||||||
|
|
||||||
focus = {
|
focus = {
|
||||||
mouseWarping = "container";
|
mouseWarping = "container";
|
||||||
|
@ -34,7 +34,7 @@
|
||||||
# Give apps that don't have them borders
|
# Give apps that don't have them borders
|
||||||
{
|
{
|
||||||
criteria = { con_mark = "giveborder"; };
|
criteria = { con_mark = "giveborder"; };
|
||||||
command = ''border pixel ${config.look.border.string}'';
|
command = ''border pixel ${config.vars.border.string}'';
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
criteria = { class = "steam"; };
|
criteria = { class = "steam"; };
|
||||||
|
@ -56,22 +56,22 @@
|
||||||
};
|
};
|
||||||
assigns = {
|
assigns = {
|
||||||
# Browser
|
# Browser
|
||||||
"1:${config.ws.w1}" = [{ app_id = "librewolf"; }];
|
"1:${w1}" = [{ app_id = "librewolf"; }];
|
||||||
|
|
||||||
# Communication
|
# Communication
|
||||||
"7:${config.ws.w7}" = [
|
"7:${w7}" = [
|
||||||
{ app_id = "teams-for-linux"; }
|
{ app_id = "teams-for-linux"; }
|
||||||
{ app_id = "vesktop"; }
|
{ app_id = "vesktop"; }
|
||||||
{ class = "vesktop"; }
|
{ class = "vesktop"; }
|
||||||
];
|
];
|
||||||
"9:${config.ws.w9}" = [{ app_id = "thunderbird"; }];
|
"9:${w9}" = [{ app_id = "thunderbird"; }];
|
||||||
|
|
||||||
# Etc
|
# Etc
|
||||||
"2:${config.ws.w2}" = [
|
"2:${w2}" = [
|
||||||
{ class = "steam"; }
|
{ class = "steam"; }
|
||||||
{ app_id = "heroic"; }
|
{ app_id = "heroic"; }
|
||||||
];
|
];
|
||||||
"44:${config.ws.w4a}" = [{ app_id = "com.obsproject.Studio"; }];
|
"44:${w4a}" = [{ app_id = "com.obsproject.Studio"; }];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,49 +3,49 @@
|
||||||
wayland.windowManager.sway.config = {
|
wayland.windowManager.sway.config = {
|
||||||
colors = {
|
colors = {
|
||||||
focused = {
|
focused = {
|
||||||
border = "#${config.look.colors.prime}";
|
border = "#${config.vars.colors.prime}";
|
||||||
background = "#${config.look.colors.prime}";
|
background = "#${config.vars.colors.prime}";
|
||||||
text = "#FFFFFF";
|
text = "#FFFFFF";
|
||||||
indicator = "#${config.look.colors.actSplit}";
|
indicator = "#${config.vars.colors.actSplit}";
|
||||||
childBorder = "#${config.look.colors.prime}";
|
childBorder = "#${config.vars.colors.prime}";
|
||||||
};
|
};
|
||||||
focusedInactive = {
|
focusedInactive = {
|
||||||
border = "#${config.look.colors.accent}";
|
border = "#${config.vars.colors.accent}";
|
||||||
background = "#${config.look.colors.accent}";
|
background = "#${config.vars.colors.accent}";
|
||||||
text = "#${config.look.colors.text}";
|
text = "#${config.vars.colors.text}";
|
||||||
indicator = "#${config.look.colors.split}";
|
indicator = "#${config.vars.colors.split}";
|
||||||
childBorder = "#${config.look.colors.accent}";
|
childBorder = "#${config.vars.colors.accent}";
|
||||||
};
|
};
|
||||||
unfocused = {
|
unfocused = {
|
||||||
border = "#${config.look.colors.dark}";
|
border = "#${config.vars.colors.dark}";
|
||||||
background = "#${config.look.colors.dark}";
|
background = "#${config.vars.colors.dark}";
|
||||||
text = "#${config.look.colors.text}";
|
text = "#${config.vars.colors.text}";
|
||||||
indicator = "#${config.look.colors.split}";
|
indicator = "#${config.vars.colors.split}";
|
||||||
childBorder = "#${config.look.colors.split}";
|
childBorder = "#${config.vars.colors.split}";
|
||||||
};
|
};
|
||||||
urgent = {
|
urgent = {
|
||||||
border = "#${config.look.colors.urgent}";
|
border = "#${config.vars.colors.urgent}";
|
||||||
background = "#${config.look.colors.urgent}";
|
background = "#${config.vars.colors.urgent}";
|
||||||
text = "#${config.look.colors.text}";
|
text = "#${config.vars.colors.text}";
|
||||||
indicator = "#${config.look.colors.urgent}";
|
indicator = "#${config.vars.colors.urgent}";
|
||||||
childBorder = "#${config.look.colors.urgent}";
|
childBorder = "#${config.vars.colors.urgent}";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
bars = [ ];
|
bars = [ ];
|
||||||
|
|
||||||
fonts = {
|
fonts = {
|
||||||
names = [ config.look.fonts.main ];
|
names = [ config.vars.fonts.main ];
|
||||||
size = 10.5;
|
size = 10.5;
|
||||||
};
|
};
|
||||||
|
|
||||||
window = {
|
window = {
|
||||||
border = config.look.border.int;
|
border = config.vars.border.int;
|
||||||
hideEdgeBorders = "smart";
|
hideEdgeBorders = "smart";
|
||||||
};
|
};
|
||||||
|
|
||||||
floating = {
|
floating = {
|
||||||
border = config.look.border.int;
|
border = config.vars.border.int;
|
||||||
titlebar = false;
|
titlebar = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, name, ... }:
|
{ config, name, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./devices
|
./devices
|
||||||
|
@ -7,12 +7,9 @@
|
||||||
./services
|
./services
|
||||||
./settings
|
./settings
|
||||||
./users
|
./users
|
||||||
|
./variables
|
||||||
];
|
];
|
||||||
|
|
||||||
options.system = with lib; {
|
networking.hostName = name;
|
||||||
desktop.enable = mkEnableOption "Desktop apps and services";
|
deployment.tags = config.system.nixos.tags;
|
||||||
server.enable = mkEnableOption "Server apps and services";
|
|
||||||
};
|
|
||||||
|
|
||||||
config.networking.hostName = name;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
enable = config.system.desktop.enable;
|
enable = builtins.elem "pc" config.system.nixos.tags;
|
||||||
wireplumber.extraConfig."wireplumber.settings"."bluetooth.autoswitch-to-headset-profile" = false;
|
|
||||||
alsa = {
|
alsa = {
|
||||||
enable = true;
|
enable = true;
|
||||||
support32Bit = true;
|
support32Bit = true;
|
||||||
};
|
};
|
||||||
pulse.enable = true;
|
pulse.enable = true;
|
||||||
#jack.enable = true;
|
#jack.enable = true;
|
||||||
|
wireplumber.extraConfig."wireplumber.settings"."bluetooth.autoswitch-to-headset-profile" = false;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
config = lib.mkIf config.system.desktop.enable {
|
config = lib.mkIf (builtins.elem "pc" config.system.nixos.tags) {
|
||||||
hardware.bluetooth = {
|
hardware.bluetooth = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
|
@ -8,9 +8,7 @@
|
||||||
Policy.AutoEnable = "true";
|
Policy.AutoEnable = "true";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
environment = {
|
|
||||||
systemPackages = with pkgs; [ bluetui ];
|
environment.persistence."/persist".directories = [ "/var/lib/bluetooth" ];
|
||||||
persistence."/persist".directories = [ "/var/lib/bluetooth" ];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
|
|
||||||
boot = {
|
boot = {
|
||||||
kernelPackages = lib.mkDefault pkgs.linuxPackages_latest;
|
kernelPackages = lib.mkDefault pkgs.linuxPackages_latest;
|
||||||
kernelParams = [ "nouveau.config=NvGspRm=1" ];
|
|
||||||
blacklistedKernelModules = [ "pcspkr" ];
|
blacklistedKernelModules = [ "pcspkr" ];
|
||||||
kernel.sysctl = {
|
kernel.sysctl = {
|
||||||
"vm.max_map_count" = 2147483642;
|
"vm.max_map_count" = 2147483642;
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
./disks
|
./disks
|
||||||
./networking
|
./networking
|
||||||
./printing
|
./printing
|
||||||
|
./tlp
|
||||||
./udev
|
./udev
|
||||||
./video
|
./video
|
||||||
];
|
];
|
||||||
|
|
|
@ -2,17 +2,20 @@
|
||||||
{
|
{
|
||||||
boot = {
|
boot = {
|
||||||
supportedFilesystems = {
|
supportedFilesystems = {
|
||||||
ntfs = config.system.desktop.enable;
|
ntfs = builtins.elem "pc" config.system.nixos.tags;
|
||||||
zfs = config.system.server.enable;
|
zfs = builtins.elem "server" config.system.nixos.tags;
|
||||||
};
|
};
|
||||||
swraid = {
|
swraid = {
|
||||||
enable = config.system.server.enable;
|
enable = builtins.elem "server" config.system.nixos.tags;
|
||||||
mdadmConf = "MAILADDR contact@nixfox.ca";
|
mdadmConf = "MAILADDR contact@nixfox.ca";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services = lib.mkIf config.environment.persistence."/persist".enable {
|
services = lib.mkIf config.environment.persistence."/persist".enable {
|
||||||
btrfs.autoScrub.enable = true;
|
btrfs.autoScrub = {
|
||||||
|
enable = true;
|
||||||
|
interval = "weekly";
|
||||||
|
};
|
||||||
fstrim.enable = true;
|
fstrim.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
|
./mounts
|
||||||
./mycelium
|
./mycelium
|
||||||
./nameservers
|
./nameservers
|
||||||
./wireless
|
./wireless
|
||||||
|
|
32
modules/system/devices/networking/mounts/default.nix
Normal file
32
modules/system/devices/networking/mounts/default.nix
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
{ config, lib, nodes, ... }:
|
||||||
|
{
|
||||||
|
fileSystems = let
|
||||||
|
netOpts = [
|
||||||
|
"noauto"
|
||||||
|
"soft"
|
||||||
|
"x-systemd.automount"
|
||||||
|
];
|
||||||
|
in with nodes; {
|
||||||
|
"midas" = {
|
||||||
|
enable = lib.mkDefault false;
|
||||||
|
device = "[${midas.config.deployment.targetHost}]:/storage";
|
||||||
|
mountPoint = "/network/Midas";
|
||||||
|
fsType = "nfs4";
|
||||||
|
options = netOpts;
|
||||||
|
};
|
||||||
|
"kitty" = {
|
||||||
|
enable = lib.mkDefault false;
|
||||||
|
device = "[${kitty.config.deployment.targetHost}]:/storage";
|
||||||
|
mountPoint = "/network/Kitty";
|
||||||
|
fsType = "nfs4";
|
||||||
|
options = netOpts;
|
||||||
|
};
|
||||||
|
"prophet" = {
|
||||||
|
enable = lib.mkDefault false;
|
||||||
|
device = "[${prophet.config.deployment.targetHost}]:/storage";
|
||||||
|
mountPoint = "/network/Prophet";
|
||||||
|
fsType = "nfs4";
|
||||||
|
options = netOpts;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,7 +1,7 @@
|
||||||
{ config, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
networking.wireless = {
|
networking.wireless = {
|
||||||
enable = config.system.desktop.enable;
|
enable = true;
|
||||||
userControlled.enable = true;
|
userControlled.enable = true;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
{
|
{
|
||||||
services = {
|
services = {
|
||||||
printing = {
|
printing = {
|
||||||
enable = config.system.desktop.enable;
|
enable = builtins.elem "pc" config.system.nixos.tags;
|
||||||
drivers = with pkgs; [ hplip ];
|
drivers = with pkgs; [ hplip ];
|
||||||
};
|
};
|
||||||
avahi = {
|
avahi = {
|
||||||
|
|
31
modules/system/devices/tlp/default.nix
Normal file
31
modules/system/devices/tlp/default.nix
Normal file
|
@ -0,0 +1,31 @@
|
||||||
|
{ config, ... }:
|
||||||
|
{
|
||||||
|
services.tlp = {
|
||||||
|
enable = true;
|
||||||
|
settings = let
|
||||||
|
leastBat = 80;
|
||||||
|
maxBat = 85;
|
||||||
|
in {
|
||||||
|
# Stop battery charging after threshold
|
||||||
|
START_CHARGE_THRESH_BAT0 = leastBat;
|
||||||
|
STOP_CHARGE_THRESH_BAT0 = maxBat;
|
||||||
|
START_CHARGE_THRESH_BAT1 = leastBat;
|
||||||
|
STOP_CHARGE_THRESH_BAT1 = maxBat;
|
||||||
|
|
||||||
|
# Change CPU energy/performance policy to power
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
|
||||||
|
|
||||||
|
# Enable the platform profile low-power
|
||||||
|
PLATFORM_PROFILE_ON_AC = "performance";
|
||||||
|
PLATFORM_PROFILE_ON_BAT = "low-power";
|
||||||
|
|
||||||
|
# Disable turbo boost
|
||||||
|
CPU_BOOST_ON_AC = 1;
|
||||||
|
CPU_BOOST_ON_BAT = 0;
|
||||||
|
|
||||||
|
CPU_HWP_DYN_BOOST_ON_AC = 1;
|
||||||
|
CPU_HWP_DYN_BOOST_ON_BAT = 0;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,6 +1,7 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
services.udev.packages = with pkgs; lib.mkIf config.system.desktop.enable [
|
services.udev.packages = with pkgs; [
|
||||||
|
android-udev-rules
|
||||||
game-devices-udev-rules
|
game-devices-udev-rules
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
imports = [ ./nvidia ];
|
imports = [ ./nvidia ];
|
||||||
|
|
||||||
hardware.graphics = {
|
hardware.graphics = {
|
||||||
enable = config.system.desktop.enable;
|
enable = builtins.elem "pc" config.system.nixos.tags;
|
||||||
enable32Bit = if config.nixpkgs.hostPlatform.linuxArch == "x86_64" then true else false;
|
enable32Bit = if config.nixpkgs.hostPlatform.linuxArch == "x86_64" then true else false;
|
||||||
extraPackages = with pkgs; [
|
extraPackages = with pkgs; [
|
||||||
vulkan-loader
|
vulkan-loader
|
||||||
|
|
|
@ -1,20 +1,18 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
options.system.nvidia.enable = lib.mkEnableOption "Nvidia graphic drivers";
|
config = lib.mkIf (lib.elem "nvidia" config.services.xserver.videoDrivers) {
|
||||||
|
boot.kernelParams = [ "nvidia_drm.fbdev=1" ]; # Framebuffer fixes TTY access
|
||||||
|
|
||||||
config = lib.mkIf config.system.nvidia.enable {
|
|
||||||
hardware.nvidia = {
|
hardware.nvidia = {
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
nvidiaSettings = false;
|
nvidiaSettings = false;
|
||||||
open = true;
|
open = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
boot.kernelParams = [ "nvidia_drm.fbdev=1" ]; # Framebuffer fixes TTY access
|
|
||||||
|
|
||||||
services.xserver.videoDrivers = [ "nvidia" ];
|
|
||||||
|
|
||||||
nixpkgs.allowUnfreePackages = [ "nvidia-x11" ];
|
nixpkgs.allowUnfreePackages = [ "nvidia-x11" ];
|
||||||
|
|
||||||
specialisation.nouveau.configuration.config.system.nvidia.enable = lib.mkForce false;
|
specialisation.nouveau.configuration.config.services.xserver.videoDrivers = lib.mkForce [ "nouveau" ];
|
||||||
|
} // {
|
||||||
|
boot.kernelParams = [ "nouveau.config=NvGspRm=1" ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
config = lib.mkIf config.system.desktop.enable {
|
config = lib.mkIf (builtins.elem "pc" config.system.nixos.tags) {
|
||||||
programs.sway.enable = true;
|
programs.sway.enable = true;
|
||||||
security.pam.services.swaylock = {};
|
security.pam.services.swaylock = {};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
programs.gamemode = {
|
programs.gamemode = {
|
||||||
enable = config.system.desktop.enable;
|
enable = builtins.elem "pc" config.system.nixos.tags;
|
||||||
settings = {
|
settings = {
|
||||||
general.renice = 10;
|
general.renice = 10;
|
||||||
gpu = {
|
gpu = {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
programs.udevil.enable = config.system.desktop.enable;
|
programs.udevil.enable = true;
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
|
@ -6,7 +6,6 @@
|
||||||
./libvirtd
|
./libvirtd
|
||||||
./snowflake
|
./snowflake
|
||||||
./ssh
|
./ssh
|
||||||
./tlp
|
|
||||||
./userborn
|
./userborn
|
||||||
./vmware
|
./vmware
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
config = lib.mkIf config.system.desktop.enable {
|
config = lib.mkIf (builtins.elem "pc" config.system.nixos.tags) {
|
||||||
services.greetd = {
|
services.greetd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings.default_session.command = lib.mkDefault (lib.strings.concatStringsSep " " [
|
settings.default_session.command = lib.mkDefault (lib.strings.concatStringsSep " " [
|
||||||
|
|
|
@ -14,13 +14,15 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.virt-manager.enable = true;
|
# Isolate devices into more IOMMU groups
|
||||||
|
boot.kernelParams = [
|
||||||
networking.firewall.trustedInterfaces = [
|
"pcie_acs_override=downstream,multifunction"
|
||||||
"virbr0"
|
"pci=routeirq"
|
||||||
"virbr1"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
|
programs.virt-manager.enable = true;
|
||||||
|
|
||||||
|
# Allow looking glass to be accessed by users
|
||||||
systemd.tmpfiles.rules = [ "f /dev/shm/looking-glass 0660 - libvirtd -" ];
|
systemd.tmpfiles.rules = [ "f /dev/shm/looking-glass 0660 - libvirtd -" ];
|
||||||
|
|
||||||
environment.persistence."/persist".directories = [ "/var/lib/libvirt" ];
|
environment.persistence."/persist".directories = [ "/var/lib/libvirt" ];
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
services.tlp.enable = config.system.desktop.enable;
|
|
||||||
}
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
config = lib.mkIf config.services.cloudflare-dyndns.enable {
|
config = lib.mkIf config.services.cloudflare-dyndns.enable {
|
||||||
services.cloudflare-dyndns.apiTokenFile = "/var/lib/private/cloudflare-dyndns/key";
|
services.cloudflare-dyndns.apiTokenFile = "/var/lib/private/cloudflare-dyndns/key";
|
||||||
|
|
|
@ -5,7 +5,6 @@
|
||||||
./forgejo
|
./forgejo
|
||||||
./icecast
|
./icecast
|
||||||
./jellyfin
|
./jellyfin
|
||||||
./lemmy
|
|
||||||
./mailserver
|
./mailserver
|
||||||
./mastodon
|
./mastodon
|
||||||
./matrix
|
./matrix
|
||||||
|
|
|
@ -8,17 +8,17 @@
|
||||||
lfs.enable = true;
|
lfs.enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
server = {
|
server = {
|
||||||
DOMAIN = "git.nixfox.ca";
|
DOMAIN = "git.${config.vars.mainDomain}";
|
||||||
ROOT_URL = "https://git.nixfox.ca:443";
|
ROOT_URL = "https://git.${config.vars.mainDomain}:443";
|
||||||
HTTP_PORT = 3110;
|
HTTP_PORT = 3110;
|
||||||
SSH_PORT = 2299;
|
SSH_PORT = 2299;
|
||||||
START_SSH_SERVER = true;
|
START_SSH_SERVER = true;
|
||||||
};
|
};
|
||||||
mailer = {
|
mailer = {
|
||||||
ENABLED = true;
|
ENABLED = true;
|
||||||
SMTP_ADDR = "mx.nixfox.ca";
|
SMTP_ADDR = "mx.${config.vars.mainDomain}";
|
||||||
FROM = "NixFox Git <noreply@nixfox.ca>";
|
FROM = "NixFox Git <noreply@${config.vars.mainDomain}>";
|
||||||
USER = "noreply@nixfox.ca";
|
USER = "noreply@${config.vars.mainDomain}";
|
||||||
PASSWD = config.secrets.mailPass.nixfoxNoReply;
|
PASSWD = config.secrets.mailPass.nixfoxNoReply;
|
||||||
PROTOCOL = "smtps";
|
PROTOCOL = "smtps";
|
||||||
};
|
};
|
||||||
|
@ -32,7 +32,7 @@
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [ 2299 ];
|
networking.firewall.allowedTCPPorts = [ 2299 ];
|
||||||
|
|
||||||
services.cloudflare-dyndns.domains = [ "git.nixfox.ca" ];
|
services.cloudflare-dyndns.domains = [ "git.${config.vars.mainDomain}" ];
|
||||||
|
|
||||||
environment.persistence."/persist".directories = [ "/var/lib/forgejo" ];
|
environment.persistence."/persist".directories = [ "/var/lib/forgejo" ];
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
services.nginx.virtualHosts."git.nixfox.ca" = lib.mkIf config.services.forgejo.enable {
|
services.nginx.virtualHosts."git.${config.vars.mainDomain}" = lib.mkIf config.services.forgejo.enable {
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
locations."/" = {
|
locations."/" = {
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue