flake: reformat with nixfmt
This commit is contained in:
parent
a79e641851
commit
eaf4f56ac0
117 changed files with 2667 additions and 1592 deletions
|
@ -1,4 +1,10 @@
|
|||
{ config, pkgs, lib, ... }: {
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = lib.lists.flatten [
|
||||
./hardware-configuration.nix
|
||||
./filesystems.nix
|
||||
|
@ -69,7 +75,6 @@
|
|||
razergenie # TODO: replace with polychromatic
|
||||
];
|
||||
|
||||
|
||||
programs.ns-usbloader.enable = true;
|
||||
programs.minipro.enable = true;
|
||||
|
||||
|
@ -90,11 +95,13 @@
|
|||
address = [ "10.10.0.3/32" ];
|
||||
listenPort = 51820;
|
||||
privateKeyFile = "/home/infinidoge/tmp/bb-vpn.key";
|
||||
peers = [{
|
||||
publicKey = "SYpnrGvxx8l4w9c7KVRVW6GyNDr/iK+maPPMw/Ua7XY=";
|
||||
allowedIPs = [ "10.9.0.0/24" ];
|
||||
endpoint = "66.23.193.252:55555";
|
||||
persistentKeepalive = 25;
|
||||
}];
|
||||
peers = [
|
||||
{
|
||||
publicKey = "SYpnrGvxx8l4w9c7KVRVW6GyNDr/iK+maPPMw/Ua7XY=";
|
||||
allowedIPs = [ "10.9.0.0/24" ];
|
||||
endpoint = "66.23.193.252:55555";
|
||||
persistentKeepalive = 25;
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -7,14 +7,22 @@ let
|
|||
backup = uuid "dabfc36b-20d1-4b09-8f55-4f9df7499741";
|
||||
hydrus = uuid "2a025f29-4058-4a76-8f38-483f0925375d";
|
||||
|
||||
commonOptions = [ "autodefrag" "noatime" "ssd" ];
|
||||
commonOptions = [
|
||||
"autodefrag"
|
||||
"noatime"
|
||||
"ssd"
|
||||
];
|
||||
in
|
||||
{
|
||||
fileSystems = {
|
||||
"/" = {
|
||||
device = "none";
|
||||
fsType = "tmpfs";
|
||||
options = [ "defaults" "size=28G" "mode=755" ];
|
||||
options = [
|
||||
"defaults"
|
||||
"size=28G"
|
||||
"mode=755"
|
||||
];
|
||||
};
|
||||
|
||||
"/media/main" = {
|
||||
|
|
|
@ -1,7 +1,13 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
boot.initrd.availableKernelModules = [ "nvme" "ahci" "xhci_pci" "usbhid" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"ahci"
|
||||
"xhci_pci"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ config, common, secrets, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
secrets,
|
||||
...
|
||||
}:
|
||||
let
|
||||
domain = common.subdomain "auth";
|
||||
ldap = common.subdomain "ldap";
|
||||
|
@ -32,7 +37,10 @@ in
|
|||
environmentFile = secrets.authentik-ldap;
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 3389 6636 ];
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
3389
|
||||
6636
|
||||
];
|
||||
|
||||
security.acme.certs.${ldap} = {
|
||||
group = "nginx";
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ config, common, inputs, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
inputs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
domain = common.subdomain "matrix";
|
||||
cfg = config.services.conduwuit;
|
||||
|
|
|
@ -1,4 +1,11 @@
|
|||
{ config, lib, pkgs, private, ... }: {
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
private,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./disks.nix
|
||||
|
@ -57,19 +64,39 @@
|
|||
|
||||
networking = {
|
||||
firewall = {
|
||||
allowedUDPPorts = [ 80 443 ];
|
||||
allowedTCPPorts = [ 80 443 25565 ];
|
||||
allowedUDPPorts = [
|
||||
80
|
||||
443
|
||||
];
|
||||
allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
25565
|
||||
];
|
||||
};
|
||||
|
||||
bridges = {
|
||||
br0 = {
|
||||
interfaces = [ "eno1" "eno2" "eno3" "eno4" ];
|
||||
interfaces = [
|
||||
"eno1"
|
||||
"eno2"
|
||||
"eno3"
|
||||
"eno4"
|
||||
];
|
||||
};
|
||||
};
|
||||
interfaces.br0.ipv4.addresses = [{ address = "192.168.137.11"; prefixLength = 24; }];
|
||||
interfaces.br0.ipv4.addresses = [
|
||||
{
|
||||
address = "192.168.137.11";
|
||||
prefixLength = 24;
|
||||
}
|
||||
];
|
||||
dhcpcd.denyInterfaces = [ "eno*" ];
|
||||
|
||||
defaultGateway = { address = "192.168.137.1"; interface = "br0"; };
|
||||
defaultGateway = {
|
||||
address = "192.168.137.1";
|
||||
interface = "br0";
|
||||
};
|
||||
|
||||
nat = {
|
||||
enable = true;
|
||||
|
@ -89,10 +116,12 @@
|
|||
|
||||
services.fail2ban.enable = true;
|
||||
|
||||
environment.etc."fail2ban/filter.d/nginx-url-probe.local".text = lib.mkDefault (lib.mkAfter ''
|
||||
[Definition]
|
||||
failregex = ^<HOST>.*GET.*(\.php|admin|wp\-).* HTTP/\d.\d\" 404.*$
|
||||
'');
|
||||
environment.etc."fail2ban/filter.d/nginx-url-probe.local".text = lib.mkDefault (
|
||||
lib.mkAfter ''
|
||||
[Definition]
|
||||
failregex = ^<HOST>.*GET.*(\.php|admin|wp\-).* HTTP/\d.\d\" 404.*$
|
||||
''
|
||||
);
|
||||
|
||||
services.fail2ban.jails.nginx-url-probe.settings = {
|
||||
enabled = true;
|
||||
|
@ -127,22 +156,26 @@
|
|||
|
||||
services.minecraft-servers.servers.emd-server.autoStart = lib.mkForce false;
|
||||
|
||||
services.borgbackup.jobs."persist" = let tmux = lib.getExe pkgs.tmux; in {
|
||||
preHook = ''
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys "say Server is backing up..." Enter
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys save-off Enter
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys save-all Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys "say Server is backing up..." Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys save-off Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys save-all Enter
|
||||
'';
|
||||
postHook = ''
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys save-on Enter
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys "say Backup complete" Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys save-on Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys "say Backup complete" Enter
|
||||
'';
|
||||
};
|
||||
services.borgbackup.jobs."persist" =
|
||||
let
|
||||
tmux = lib.getExe pkgs.tmux;
|
||||
in
|
||||
{
|
||||
preHook = ''
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys "say Server is backing up..." Enter
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys save-off Enter
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys save-all Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys "say Server is backing up..." Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys save-off Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys save-all Enter
|
||||
'';
|
||||
postHook = ''
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys save-on Enter
|
||||
${tmux} -S /run/minecraft/friend-server.sock send-keys "say Backup complete" Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys save-on Enter
|
||||
${tmux} -S /run/minecraft/sister-server.sock send-keys "say Backup complete" Enter
|
||||
'';
|
||||
};
|
||||
|
||||
systemd.services.setup-infiniband = {
|
||||
wantedBy = [ "network.target" ];
|
||||
|
|
|
@ -3,7 +3,10 @@ with lib.our.disko;
|
|||
{
|
||||
boot.kernelPackages = pkgs.linuxPackages;
|
||||
|
||||
boot.zfs.extraPools = [ "zssd" "zhdd" ];
|
||||
boot.zfs.extraPools = [
|
||||
"zssd"
|
||||
"zhdd"
|
||||
];
|
||||
|
||||
disko.devices = {
|
||||
nodev."/" = mkTmpfs "64G";
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ config, common, secrets, pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
secrets,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg = config.services.forgejo;
|
||||
domain = common.subdomain "git";
|
||||
|
|
|
@ -5,12 +5,22 @@
|
|||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ehci_pci" "uhci_hcd" "hpsa" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"ehci_pci"
|
||||
"uhci_hcd"
|
||||
"hpsa"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.kernelParams = [ "boot.shell_on_fail" ];
|
||||
boot.supportedFilesystems = [ "btrfs" "zfs" ];
|
||||
boot.supportedFilesystems = [
|
||||
"btrfs"
|
||||
"zfs"
|
||||
];
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
|
||||
info.model = "HPE ProLiant DL360 Gen 9";
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ config, common, secrets, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
secrets,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg = config.services.hedgedoc;
|
||||
domain = common.subdomain "md";
|
||||
|
@ -12,7 +17,10 @@ in
|
|||
protocolUseSSL = true;
|
||||
port = 4003;
|
||||
|
||||
db = { dialect = "sqlite"; storage = "/srv/hedgedoc/db.sqlite"; };
|
||||
db = {
|
||||
dialect = "sqlite";
|
||||
storage = "/srv/hedgedoc/db.sqlite";
|
||||
};
|
||||
uploadsPath = "/srv/hedgedoc/uploads";
|
||||
|
||||
allowFreeURL = true;
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ config, common, secrets, pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
secrets,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
domain = common.subdomain "hydra";
|
||||
in
|
||||
|
@ -61,7 +67,12 @@ in
|
|||
{
|
||||
hostName = "localhost";
|
||||
system = "x86_64-linux";
|
||||
supportedFeatures = [ "kvm" "nixos-test" "big-parallel" "benchmark" ];
|
||||
supportedFeatures = [
|
||||
"kvm"
|
||||
"nixos-test"
|
||||
"big-parallel"
|
||||
"benchmark"
|
||||
];
|
||||
protocol = null;
|
||||
maxJobs = 32;
|
||||
speedFactor = 16;
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ config, pkgs, common, ... }:
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
common,
|
||||
...
|
||||
}:
|
||||
let
|
||||
domain = common.subdomain "photos";
|
||||
cfg = config.services.immich;
|
||||
|
|
|
@ -25,9 +25,11 @@ in
|
|||
locations."/" = {
|
||||
proxyPass = jellyfin;
|
||||
recommendedProxySettings = false;
|
||||
extraConfig = proxyConfig + ''
|
||||
proxy_buffering off;
|
||||
'';
|
||||
extraConfig =
|
||||
proxyConfig
|
||||
+ ''
|
||||
proxy_buffering off;
|
||||
'';
|
||||
};
|
||||
|
||||
locations."= /web/" = {
|
||||
|
@ -51,5 +53,9 @@ in
|
|||
openFirewall = true;
|
||||
};
|
||||
|
||||
persist.directories = with config.services.jellyfin; [ dataDir cacheDir logDir ];
|
||||
persist.directories = with config.services.jellyfin; [
|
||||
dataDir
|
||||
cacheDir
|
||||
logDir
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,11 +1,22 @@
|
|||
{ config, common, pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg = config.services.jupyter;
|
||||
|
||||
mkPythonKernel = displayName: env: {
|
||||
inherit displayName;
|
||||
language = "python";
|
||||
argv = [ "${env.interpreter}" "-m" "ipykernel_launcher" "-f" "{connection_file}" ];
|
||||
argv = [
|
||||
"${env.interpreter}"
|
||||
"-m"
|
||||
"ipykernel_launcher"
|
||||
"-f"
|
||||
"{connection_file}"
|
||||
];
|
||||
logo32 = "${env}/${env.sitePackages}/ipykernel/resources/logo-32x32.png";
|
||||
logo64 = "${env}/${env.sitePackages}/ipykernel/resources/logo-64x64.png";
|
||||
};
|
||||
|
@ -59,24 +70,32 @@ in
|
|||
notebookDir = "~/Notebooks";
|
||||
|
||||
kernels = {
|
||||
python3 = mkPythonKernel "Python 3" (pkgs.python3.withPackages (p: with p; [
|
||||
ipykernel
|
||||
python3 = mkPythonKernel "Python 3" (
|
||||
pkgs.python3.withPackages (
|
||||
p: with p; [
|
||||
ipykernel
|
||||
|
||||
matplotlib
|
||||
numpy
|
||||
pandas
|
||||
scipy
|
||||
]));
|
||||
vpython = mkPythonKernel "VPython" (pkgs.python3.withPackages (p: with p; [
|
||||
ipykernel
|
||||
jupyterlab-vpython
|
||||
matplotlib
|
||||
numpy
|
||||
pandas
|
||||
scipy
|
||||
]
|
||||
)
|
||||
);
|
||||
vpython = mkPythonKernel "VPython" (
|
||||
pkgs.python3.withPackages (
|
||||
p: with p; [
|
||||
ipykernel
|
||||
jupyterlab-vpython
|
||||
|
||||
vpython-jupyter
|
||||
matplotlib
|
||||
numpy
|
||||
pandas
|
||||
scipy
|
||||
]));
|
||||
vpython-jupyter
|
||||
matplotlib
|
||||
numpy
|
||||
pandas
|
||||
scipy
|
||||
]
|
||||
)
|
||||
);
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -4,7 +4,13 @@ let
|
|||
directory = "/srv/postgresql";
|
||||
in
|
||||
{
|
||||
persist.directories = [{ inherit directory; user = "postgres"; group = "postgres"; }];
|
||||
persist.directories = [
|
||||
{
|
||||
inherit directory;
|
||||
user = "postgres";
|
||||
group = "postgres";
|
||||
}
|
||||
];
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ config, common, secrets, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
secrets,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg = config.services.searx;
|
||||
domain = common.subdomain "search";
|
||||
|
|
|
@ -50,8 +50,15 @@ in
|
|||
security.pam.services.sshd.allowNullPassword = true;
|
||||
|
||||
systemd.tmpfiles.settings."30-external" = {
|
||||
"/srv/external".d = { user = "root"; group = "root"; };
|
||||
"/srv/external/incoming".d = { user = "incoming"; group = "incoming"; mode = "0770"; };
|
||||
"/srv/external".d = {
|
||||
user = "root";
|
||||
group = "root";
|
||||
};
|
||||
"/srv/external/incoming".d = {
|
||||
user = "incoming";
|
||||
group = "incoming";
|
||||
mode = "0770";
|
||||
};
|
||||
};
|
||||
|
||||
# https://enotacoes.wordpress.com/2021/10/05/limiting-user-to-sshfs-or-sftp-of-one-directory-only/
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
{ config, common, pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
services.nginx.virtualHosts."thelounge.inx.moe" = common.nginx.ssl // {
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ pkgs, private, config, lib, ... }:
|
||||
{
|
||||
pkgs,
|
||||
private,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
containers.torrenting = {
|
||||
|
|
|
@ -1,4 +1,11 @@
|
|||
{ config, common, secrets, lib, pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
secrets,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
domain = common.subdomain "bitwarden";
|
||||
in
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ config, common, pkgs, lib, ... }:
|
||||
{
|
||||
config,
|
||||
common,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (common.nginx) ssl ssl-optional;
|
||||
|
||||
|
@ -14,21 +20,23 @@ let
|
|||
location ~ "/\..+" { deny all; }
|
||||
'';
|
||||
|
||||
mkWebsite = name: ssl // {
|
||||
locations."/" = {
|
||||
root = "/srv/web/${name}";
|
||||
inherit tryFiles;
|
||||
extraConfig = websiteConfig;
|
||||
mkWebsite =
|
||||
name:
|
||||
ssl
|
||||
// {
|
||||
locations."/" = {
|
||||
root = "/srv/web/${name}";
|
||||
inherit tryFiles;
|
||||
extraConfig = websiteConfig;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
mkRedirect = from: to: ssl-optional // { globalRedirect = to; };
|
||||
|
||||
websites = lib.genAttrs [
|
||||
"inx.moe"
|
||||
"stickers.inx.moe"
|
||||
]
|
||||
mkWebsite;
|
||||
] mkWebsite;
|
||||
|
||||
redirects = lib.mapAttrs mkRedirect {
|
||||
"nitter.inx.moe" = "twitter.com";
|
||||
|
@ -44,52 +52,55 @@ in
|
|||
}
|
||||
'';
|
||||
|
||||
services.nginx.virtualHosts = websites // redirects // {
|
||||
"j.inx.moe" = ssl-optional // {
|
||||
locations."/" = {
|
||||
return = "302 $jump_link";
|
||||
services.nginx.virtualHosts =
|
||||
websites
|
||||
// redirects
|
||||
// {
|
||||
"j.inx.moe" = ssl-optional // {
|
||||
locations."/" = {
|
||||
return = "302 $jump_link";
|
||||
};
|
||||
};
|
||||
"blahaj.inx.moe" = ssl-optional // {
|
||||
locations."/" = {
|
||||
tryFiles = "/Blahaj.png =404";
|
||||
root = ./static;
|
||||
};
|
||||
locations."/buy" = {
|
||||
return = "301 https://www.ikea.com/us/en/p/blahaj-soft-toy-shark-90373590/";
|
||||
};
|
||||
};
|
||||
"swedish.fish" = ssl-optional // {
|
||||
locations."/" = {
|
||||
tryFiles = "/Blahaj.png =404";
|
||||
root = ./static;
|
||||
};
|
||||
locations."/buy" = {
|
||||
return = "301 https://www.ikea.com/us/en/p/blahaj-soft-toy-shark-90373590/";
|
||||
};
|
||||
};
|
||||
"files.inx.moe" = ssl // {
|
||||
locations."/" = {
|
||||
root = "/srv/web/files.inx.moe";
|
||||
extraConfig = ''
|
||||
autoindex on;
|
||||
'';
|
||||
};
|
||||
locations."/p/" = {
|
||||
root = "/srv/web/files.inx.moe";
|
||||
};
|
||||
};
|
||||
"old.inx.moe" = ssl-optional // {
|
||||
locations."/" = {
|
||||
root = "/srv/web/inx.moe";
|
||||
inherit tryFiles;
|
||||
extraConfig = websiteConfig;
|
||||
};
|
||||
};
|
||||
"foxy.software" = ssl-optional // {
|
||||
locations."/".return = "301 https://inx.moe";
|
||||
};
|
||||
};
|
||||
"blahaj.inx.moe" = ssl-optional // {
|
||||
locations."/" = {
|
||||
tryFiles = "/Blahaj.png =404";
|
||||
root = ./static;
|
||||
};
|
||||
locations."/buy" = {
|
||||
return = "301 https://www.ikea.com/us/en/p/blahaj-soft-toy-shark-90373590/";
|
||||
};
|
||||
};
|
||||
"swedish.fish" = ssl-optional // {
|
||||
locations."/" = {
|
||||
tryFiles = "/Blahaj.png =404";
|
||||
root = ./static;
|
||||
};
|
||||
locations."/buy" = {
|
||||
return = "301 https://www.ikea.com/us/en/p/blahaj-soft-toy-shark-90373590/";
|
||||
};
|
||||
};
|
||||
"files.inx.moe" = ssl // {
|
||||
locations."/" = {
|
||||
root = "/srv/web/files.inx.moe";
|
||||
extraConfig = ''
|
||||
autoindex on;
|
||||
'';
|
||||
};
|
||||
locations."/p/" = {
|
||||
root = "/srv/web/files.inx.moe";
|
||||
};
|
||||
};
|
||||
"old.inx.moe" = ssl-optional // {
|
||||
locations."/" = {
|
||||
root = "/srv/web/inx.moe";
|
||||
inherit tryFiles;
|
||||
extraConfig = websiteConfig;
|
||||
};
|
||||
};
|
||||
"foxy.software" = ssl-optional // {
|
||||
locations."/".return = "301 https://inx.moe";
|
||||
};
|
||||
};
|
||||
|
||||
services.uwsgi = {
|
||||
enable = true;
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ config, pkgs, lib, ... }: {
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./filesystems.nix
|
||||
|
@ -11,7 +17,10 @@
|
|||
|
||||
persist = {
|
||||
directories = [
|
||||
{ directory = "/var/lib/dnsmasq/"; user = "dnsmasq"; }
|
||||
{
|
||||
directory = "/var/lib/dnsmasq/";
|
||||
user = "dnsmasq";
|
||||
}
|
||||
];
|
||||
|
||||
files = [
|
||||
|
@ -82,7 +91,10 @@
|
|||
"sys-devices-pci0000:00-0000:00:02.0-drm-card0-card0\\x2deDP\\x2d1-intel_backlight.device"
|
||||
"sys-devices-pci0000:00-0000:00:02.0-drm-card1-card1\\x2deDP\\x2d1-intel_backlight.device"
|
||||
];
|
||||
after = [ "system-systemd\\x2dbacklight.slice" "systemd-backlight@backlight:intel_backlight.service" ];
|
||||
after = [
|
||||
"system-systemd\\x2dbacklight.slice"
|
||||
"systemd-backlight@backlight:intel_backlight.service"
|
||||
];
|
||||
serviceConfig.Type = "oneshot";
|
||||
script = "${lib.getExe pkgs.brightnessctl} set 50%";
|
||||
};
|
||||
|
@ -99,8 +111,16 @@
|
|||
#}
|
||||
{
|
||||
hostName = "infini-dl360";
|
||||
systems = [ "x86_64-linux" "aarch64-linux" ];
|
||||
supportedFeatures = [ "nixos-test" "benchmark" "big-parallel" "kvm" ];
|
||||
systems = [
|
||||
"x86_64-linux"
|
||||
"aarch64-linux"
|
||||
];
|
||||
supportedFeatures = [
|
||||
"nixos-test"
|
||||
"benchmark"
|
||||
"big-parallel"
|
||||
"kvm"
|
||||
];
|
||||
protocol = "ssh-ng";
|
||||
maxJobs = 32;
|
||||
speedFactor = 16;
|
||||
|
@ -114,26 +134,33 @@
|
|||
address = [ "10.10.0.3/32" ];
|
||||
listenPort = 51820;
|
||||
privateKeyFile = "/home/infinidoge/tmp/bb-vpn.key";
|
||||
peers = [{
|
||||
publicKey = "SYpnrGvxx8l4w9c7KVRVW6GyNDr/iK+maPPMw/Ua7XY=";
|
||||
allowedIPs = [ "10.9.0.0/24" ];
|
||||
endpoint = "66.23.193.252:55555";
|
||||
persistentKeepalive = 25;
|
||||
}];
|
||||
peers = [
|
||||
{
|
||||
publicKey = "SYpnrGvxx8l4w9c7KVRVW6GyNDr/iK+maPPMw/Ua7XY=";
|
||||
allowedIPs = [ "10.9.0.0/24" ];
|
||||
endpoint = "66.23.193.252:55555";
|
||||
persistentKeepalive = 25;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
specialisation.router.configuration = {
|
||||
networking = {
|
||||
interfaces."enp0s13f0u1" = {
|
||||
ipv4.addresses = [{
|
||||
address = "192.168.100.1";
|
||||
prefixLength = 24;
|
||||
}];
|
||||
ipv4.addresses = [
|
||||
{
|
||||
address = "192.168.100.1";
|
||||
prefixLength = 24;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
firewall.interfaces."enp0s13f0u1" = {
|
||||
allowedTCPPorts = [ 53 ];
|
||||
allowedUDPPorts = [ 53 67 ];
|
||||
allowedUDPPorts = [
|
||||
53
|
||||
67
|
||||
];
|
||||
};
|
||||
|
||||
nat = {
|
||||
|
@ -146,7 +173,10 @@
|
|||
services.dnsmasq = {
|
||||
enable = true;
|
||||
settings = {
|
||||
server = [ "8.8.8.8" "1.1.1.1" ];
|
||||
server = [
|
||||
"8.8.8.8"
|
||||
"1.1.1.1"
|
||||
];
|
||||
domain-needed = true;
|
||||
bogus-priv = true;
|
||||
no-resolv = true;
|
||||
|
|
|
@ -13,12 +13,26 @@ in
|
|||
|
||||
services.autorandr.profiles =
|
||||
let
|
||||
scale = { x = scaleFactor'; y = scaleFactor'; };
|
||||
scale = {
|
||||
x = scaleFactor';
|
||||
y = scaleFactor';
|
||||
};
|
||||
config = {
|
||||
framework = { mode = "2256x1504"; primary = true; inherit scale; };
|
||||
portable-second = { mode = "1920x1080"; rotate = "left"; };
|
||||
dock = { mode = "1280x1024"; };
|
||||
dorm = { mode = "1920x1080"; };
|
||||
framework = {
|
||||
mode = "2256x1504";
|
||||
primary = true;
|
||||
inherit scale;
|
||||
};
|
||||
portable-second = {
|
||||
mode = "1920x1080";
|
||||
rotate = "left";
|
||||
};
|
||||
dock = {
|
||||
mode = "1280x1024";
|
||||
};
|
||||
dorm = {
|
||||
mode = "1920x1080";
|
||||
};
|
||||
};
|
||||
fingerprints = {
|
||||
framework = "00ffffffffffff0009e5ca0b000000002f200104a51c137803de50a3544c99260f505400000001010101010101010101010101010101115cd01881e02d50302036001dbe1000001aa749d01881e02d50302036001dbe1000001a000000fe00424f452043510a202020202020000000fe004e4531333546424d2d4e34310a0073";
|
||||
|
@ -32,30 +46,57 @@ in
|
|||
config = lib.mapAttrs (_: v: lib.removeAttrs v [ "fingerprint" ]) config;
|
||||
};
|
||||
in
|
||||
lib.mapAttrs (_: mkConfig) (with config'; {
|
||||
main = {
|
||||
eDP-1 = framework // { position = "0x0"; };
|
||||
};
|
||||
portable-second = {
|
||||
eDP-1 = framework // { position = "1080x716"; };
|
||||
DP-4 = portable-second // { position = "0x0"; };
|
||||
};
|
||||
docked = {
|
||||
eDP-1 = framework // { position = "0x210"; };
|
||||
DP-1-3 = dock // { position = "1805x0"; };
|
||||
};
|
||||
docked-alt = {
|
||||
eDP-1 = framework // { position = "1080x716"; };
|
||||
DP-4 = portable-second // { position = "0x0"; };
|
||||
DP-1-3 = dock // { position = "2885x506"; };
|
||||
};
|
||||
dorm = {
|
||||
eDP-1 = framework // { position = "1920x0"; };
|
||||
DP-4 = dorm // { position = "0x0"; };
|
||||
};
|
||||
dorm-2 = {
|
||||
eDP-1 = framework // { position = "1920x0"; };
|
||||
DP-3 = dorm // { position = "0x0"; };
|
||||
};
|
||||
});
|
||||
lib.mapAttrs (_: mkConfig) (
|
||||
with config';
|
||||
{
|
||||
main = {
|
||||
eDP-1 = framework // {
|
||||
position = "0x0";
|
||||
};
|
||||
};
|
||||
portable-second = {
|
||||
eDP-1 = framework // {
|
||||
position = "1080x716";
|
||||
};
|
||||
DP-4 = portable-second // {
|
||||
position = "0x0";
|
||||
};
|
||||
};
|
||||
docked = {
|
||||
eDP-1 = framework // {
|
||||
position = "0x210";
|
||||
};
|
||||
DP-1-3 = dock // {
|
||||
position = "1805x0";
|
||||
};
|
||||
};
|
||||
docked-alt = {
|
||||
eDP-1 = framework // {
|
||||
position = "1080x716";
|
||||
};
|
||||
DP-4 = portable-second // {
|
||||
position = "0x0";
|
||||
};
|
||||
DP-1-3 = dock // {
|
||||
position = "2885x506";
|
||||
};
|
||||
};
|
||||
dorm = {
|
||||
eDP-1 = framework // {
|
||||
position = "1920x0";
|
||||
};
|
||||
DP-4 = dorm // {
|
||||
position = "0x0";
|
||||
};
|
||||
};
|
||||
dorm-2 = {
|
||||
eDP-1 = framework // {
|
||||
position = "1920x0";
|
||||
};
|
||||
DP-3 = dorm // {
|
||||
position = "0x0";
|
||||
};
|
||||
};
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
|
@ -1,7 +1,13 @@
|
|||
{ lib, ... }:
|
||||
|
||||
{
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"thunderbolt"
|
||||
"nvme"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./filesystems.nix
|
||||
|
|
|
@ -3,7 +3,12 @@ let
|
|||
uuid = uuid: "/dev/disk/by-uuid/${uuid}";
|
||||
main = uuid "9d4bf2d8-f139-42e7-937a-541a7870d806";
|
||||
data = uuid "456cebd3-f800-4733-a783-90ed7c8978f7";
|
||||
commonOptions = [ "autodefrag" "noatime" "ssd" "compress=zstd:1" ];
|
||||
commonOptions = [
|
||||
"autodefrag"
|
||||
"noatime"
|
||||
"ssd"
|
||||
"compress=zstd:1"
|
||||
];
|
||||
|
||||
mkMain' = options: {
|
||||
device = main;
|
||||
|
@ -26,7 +31,11 @@ in
|
|||
"/" = {
|
||||
device = "none";
|
||||
fsType = "tmpfs";
|
||||
options = [ "defaults" "size=16G" "mode=755" ];
|
||||
options = [
|
||||
"defaults"
|
||||
"size=16G"
|
||||
"mode=755"
|
||||
];
|
||||
};
|
||||
|
||||
"/media/main" = mkMain' [ ];
|
||||
|
|
|
@ -1,7 +1,14 @@
|
|||
{ lib, ... }:
|
||||
|
||||
{
|
||||
boot.initrd.availableKernelModules = [ "ahci" "nvme" "sd_mod" "usb_storage" "usbhid" "xhci_pci" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"ahci"
|
||||
"nvme"
|
||||
"sd_mod"
|
||||
"usb_storage"
|
||||
"usbhid"
|
||||
"xhci_pci"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ inputs, config, lib, pkgs, ... }:
|
||||
{
|
||||
inputs,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
{
|
||||
imports = [
|
||||
|
@ -13,8 +19,7 @@ with lib;
|
|||
|
||||
nixpkgs.overlays = [
|
||||
(final: super: {
|
||||
makeModulesClosure = x:
|
||||
super.makeModulesClosure (x // { allowMissing = true; });
|
||||
makeModulesClosure = x: super.makeModulesClosure (x // { allowMissing = true; });
|
||||
})
|
||||
];
|
||||
|
||||
|
@ -31,7 +36,12 @@ with lib;
|
|||
kernelPackages = mkForce pkgs.linuxPackages_rpi4;
|
||||
|
||||
# Removes ZFS >:(
|
||||
supportedFilesystems = mkForce [ "btrfs" "ntfs" "vfat" "ext4" ];
|
||||
supportedFilesystems = mkForce [
|
||||
"btrfs"
|
||||
"ntfs"
|
||||
"vfat"
|
||||
"ext4"
|
||||
];
|
||||
|
||||
tmp.useTmpfs = true;
|
||||
# kernelParams = [
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ modulesPath, config, lib, pkgs, ... }:
|
||||
{
|
||||
modulesPath,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
#formatAttr = "sdImage";
|
||||
|
@ -18,7 +24,11 @@
|
|||
# The serial ports listed here are:
|
||||
# - ttyS0: for Tegra (Jetson TX1)
|
||||
# - ttyAMA0: for QEMU's -machine virt
|
||||
boot.kernelParams = [ "console=ttyS0,115200n8" "console=ttyAMA0,115200n8" "console=tty0" ];
|
||||
boot.kernelParams = [
|
||||
"console=ttyS0,115200n8"
|
||||
"console=ttyAMA0,115200n8"
|
||||
"console=tty0"
|
||||
];
|
||||
|
||||
#sdImage = {
|
||||
# populateFirmwareCommands =
|
||||
|
@ -34,29 +44,29 @@
|
|||
# kernel=u-boot-rpi4.bin
|
||||
# enable_gic=1
|
||||
# armstub=armstub8-gic.bin
|
||||
#
|
||||
#
|
||||
# # Otherwise the resolution will be weird in most cases, compared to
|
||||
# # what the pi3 firmware does by default.
|
||||
# disable_overscan=1
|
||||
#
|
||||
#
|
||||
# # Supported in newer board revisions
|
||||
# arm_boost=1
|
||||
#
|
||||
#
|
||||
# [cm4]
|
||||
# # Enable host mode on the 2711 built-in XHCI USB controller.
|
||||
# # This line should be removed if the legacy DWC2 controller is required
|
||||
# # (e.g. for USB device mode) or if USB support is not required.
|
||||
# otg_mode=1
|
||||
#
|
||||
#
|
||||
# [all]
|
||||
# # Boot in 64-bit mode.
|
||||
# arm_64bit=1
|
||||
#
|
||||
#
|
||||
# # U-Boot needs this to work, regardless of whether UART is actually used or not.
|
||||
# # Look in arch/arm/mach-bcm283x/Kconfig in the U-Boot tree to see if this is still
|
||||
# # a requirement in the future.
|
||||
# enable_uart=1
|
||||
#
|
||||
#
|
||||
# # Prevent the firmware from smashing the framebuffer setup done by the mainline kernel
|
||||
# # when attempting to show low-voltage or overtemperature warnings.
|
||||
# avoid_warnings=1
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./filesystems.nix
|
||||
|
@ -20,10 +21,12 @@
|
|||
|
||||
networking = {
|
||||
interfaces.eno4 = {
|
||||
ipv4.addresses = [{
|
||||
address = "128.210.6.109";
|
||||
prefixLength = 28;
|
||||
}];
|
||||
ipv4.addresses = [
|
||||
{
|
||||
address = "128.210.6.109";
|
||||
prefixLength = 28;
|
||||
}
|
||||
];
|
||||
};
|
||||
defaultGateway = {
|
||||
address = "128.210.6.97";
|
||||
|
|
|
@ -3,7 +3,11 @@
|
|||
let
|
||||
uuid = uuid: "/dev/disk/by-uuid/${uuid}";
|
||||
main = uuid "527062b3-7a48-4456-8527-30887c6e9f52";
|
||||
commonOptions = [ "autodefrag" "noatime" "compress-force=zstd:1" ];
|
||||
commonOptions = [
|
||||
"autodefrag"
|
||||
"noatime"
|
||||
"compress-force=zstd:1"
|
||||
];
|
||||
|
||||
mkMain' = options: {
|
||||
device = main;
|
||||
|
@ -17,7 +21,11 @@ in
|
|||
"/" = {
|
||||
device = "none";
|
||||
fsType = "tmpfs";
|
||||
options = [ "defaults" "size=64G" "mode=755" ];
|
||||
options = [
|
||||
"defaults"
|
||||
"size=64G"
|
||||
"mode=755"
|
||||
];
|
||||
};
|
||||
|
||||
"/media/main" = mkMain' [ ];
|
||||
|
|
|
@ -5,12 +5,25 @@
|
|||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" "ahci" "usbhid" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"thunderbolt"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ "usb_storage" ];
|
||||
boot.kernelModules = [ "kvm-amd" "kvm-intel" ];
|
||||
boot.kernelModules = [
|
||||
"kvm-amd"
|
||||
"kvm-intel"
|
||||
];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.kernelParams = [ "boot.shell_on_fail" ];
|
||||
boot.supportedFilesystems = [ "btrfs" "zfs" ];
|
||||
boot.supportedFilesystems = [
|
||||
"btrfs"
|
||||
"zfs"
|
||||
];
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
|
||||
info.model = "SD Card Installation";
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./filesystems.nix
|
||||
|
|
|
@ -7,7 +7,11 @@ let
|
|||
esp = uuid "A2B8-4C6E";
|
||||
data = uuid "59abb0ff-fe4e-4061-87d2-b728b937656a";
|
||||
|
||||
commonOptions = [ "autodefrag" "noatime" "ssd" ];
|
||||
commonOptions = [
|
||||
"autodefrag"
|
||||
"noatime"
|
||||
"ssd"
|
||||
];
|
||||
in
|
||||
{
|
||||
|
||||
|
@ -15,7 +19,11 @@ in
|
|||
"/" = {
|
||||
device = "tmpfs";
|
||||
fsType = "tmpfs";
|
||||
options = [ "defaults" "size=4G" "mode=755" ];
|
||||
options = [
|
||||
"defaults"
|
||||
"size=4G"
|
||||
"mode=755"
|
||||
];
|
||||
};
|
||||
|
||||
"/media/main" = {
|
||||
|
|
|
@ -1,9 +1,19 @@
|
|||
{ lib, ... }:
|
||||
|
||||
{
|
||||
boot.initrd.availableKernelModules = [ "nvme" "usb_storage" "xhci_pci" "ahci" "usbhid" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"usb_storage"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" "kvm-intel" ];
|
||||
boot.kernelModules = [
|
||||
"kvm-amd"
|
||||
"kvm-intel"
|
||||
];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "ondemand";
|
||||
|
|
|
@ -1,12 +1,15 @@
|
|||
{ lib, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
|
|
@ -1,4 +1,10 @@
|
|||
{ private, config, lib, pkgs, ... }:
|
||||
{
|
||||
private,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
modules.hardware.form.server = true;
|
||||
|
@ -14,40 +20,45 @@
|
|||
|
||||
home-manager.useUserPackages = false;
|
||||
|
||||
home = { main, config, ... }: {
|
||||
home = {
|
||||
username = lib.mkForce private.variables.purdue-username;
|
||||
home =
|
||||
{ main, config, ... }:
|
||||
{
|
||||
home = {
|
||||
username = lib.mkForce private.variables.purdue-username;
|
||||
|
||||
packages = with pkgs; [
|
||||
home-manager
|
||||
] ++ main.universe.packages;
|
||||
packages =
|
||||
with pkgs;
|
||||
[
|
||||
home-manager
|
||||
]
|
||||
++ main.universe.packages;
|
||||
|
||||
inherit (main.universe) shellAliases;
|
||||
inherit (main.universe) shellAliases;
|
||||
|
||||
sessionVariables = {
|
||||
TMPDIR = "${config.home.homeDirectory}/scratch/tmp";
|
||||
UNIVERSE_FLAKE_ROOT = "${config.home.homeDirectory}/universe";
|
||||
UNIVERSE_USERNAME = main.user.name;
|
||||
SHELL = "zsh";
|
||||
sessionVariables = {
|
||||
TMPDIR = "${config.home.homeDirectory}/scratch/tmp";
|
||||
UNIVERSE_FLAKE_ROOT = "${config.home.homeDirectory}/universe";
|
||||
UNIVERSE_USERNAME = main.user.name;
|
||||
SHELL = "zsh";
|
||||
};
|
||||
|
||||
file.".profile".target = ".profile-hm";
|
||||
|
||||
homeDirectory = lib.mkForce "/homes/${config.home.username}";
|
||||
};
|
||||
|
||||
file.".profile".target = ".profile-hm";
|
||||
|
||||
homeDirectory = lib.mkForce "/homes/${config.home.username}";
|
||||
nix.settings = {
|
||||
inherit (main.nix.settings)
|
||||
auto-optimise-store
|
||||
experimental-features
|
||||
fallback
|
||||
flake-registry
|
||||
keep-derivations
|
||||
keep-outputs
|
||||
min-free
|
||||
sandbox
|
||||
use-xdg-base-directories
|
||||
;
|
||||
};
|
||||
};
|
||||
|
||||
nix.settings = {
|
||||
inherit (main.nix.settings)
|
||||
auto-optimise-store
|
||||
experimental-features
|
||||
fallback
|
||||
flake-registry
|
||||
keep-derivations
|
||||
keep-outputs
|
||||
min-free
|
||||
sandbox
|
||||
use-xdg-base-directories
|
||||
;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./disks.nix
|
||||
|
|
|
@ -5,12 +5,25 @@
|
|||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" "ahci" "usbhid" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"thunderbolt"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ "usb_storage" ];
|
||||
boot.kernelModules = [ "kvm-amd" "kvm-intel" ];
|
||||
boot.kernelModules = [
|
||||
"kvm-amd"
|
||||
"kvm-intel"
|
||||
];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.kernelParams = [ "boot.shell_on_fail" ];
|
||||
boot.supportedFilesystems = [ "btrfs" "zfs" ];
|
||||
boot.supportedFilesystems = [
|
||||
"btrfs"
|
||||
"zfs"
|
||||
];
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
|
||||
info.model = "Portable Installation";
|
||||
|
|
|
@ -5,12 +5,20 @@
|
|||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.kernelParams = [ "boot.shell_on_fail" ];
|
||||
boot.supportedFilesystems = [ "btrfs" "zfs" ];
|
||||
boot.supportedFilesystems = [
|
||||
"btrfs"
|
||||
"zfs"
|
||||
];
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
|
||||
info.model = "Dell R330";
|
||||
|
|
|
@ -10,21 +10,26 @@
|
|||
|
||||
home-manager.useUserPackages = false;
|
||||
|
||||
home = { main, config, ... }: {
|
||||
home = {
|
||||
packages = with pkgs; [
|
||||
home-manager
|
||||
] ++ main.universe.packages;
|
||||
home =
|
||||
{ main, config, ... }:
|
||||
{
|
||||
home = {
|
||||
packages =
|
||||
with pkgs;
|
||||
[
|
||||
home-manager
|
||||
]
|
||||
++ main.universe.packages;
|
||||
|
||||
inherit (main.universe) shellAliases;
|
||||
inherit (main.universe) shellAliases;
|
||||
|
||||
sessionVariables = {
|
||||
UNIVERSE_FLAKE_ROOT = "${config.home.homeDirectory}/universe";
|
||||
UNIVERSE_MODE = "home-manager";
|
||||
sessionVariables = {
|
||||
UNIVERSE_FLAKE_ROOT = "${config.home.homeDirectory}/universe";
|
||||
UNIVERSE_MODE = "home-manager";
|
||||
};
|
||||
};
|
||||
};
|
||||
nix.settings.use-xdg-base-directories = true;
|
||||
nix.settings.use-xdg-base-directories = true;
|
||||
|
||||
universe.programming.all.enable = true;
|
||||
};
|
||||
universe.programming.all.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue