2023-11-18 11:29:47 +01:00
|
|
|
{ pkgs, ... }:
|
|
|
|
{
|
|
|
|
# [LOCALE]
|
|
|
|
time.timeZone = "Europe/Stockholm";
|
|
|
|
i18n.defaultLocale = "en_GB.UTF-8";
|
2023-12-01 18:33:54 +01:00
|
|
|
i18n.supportedLocales = [ "sv_SE.UTF-8/UTF-8" "en_GB.UTF-8/UTF-8" "en_US.UTF-8/UTF-8" ];
|
2023-11-18 11:29:47 +01:00
|
|
|
|
|
|
|
# [NIX]
|
|
|
|
nix = {
|
|
|
|
settings = {
|
|
|
|
bash-prompt = "\\033[1m\\u\\033[0m@\\033[1m\\h\\033[0m: \\w\\n❄\\040";
|
|
|
|
experimental-features = [ "nix-command" "flakes" ];
|
|
|
|
auto-optimise-store = true;
|
|
|
|
};
|
|
|
|
gc = {
|
|
|
|
automatic = true;
|
2024-06-24 21:53:35 +02:00
|
|
|
dates = "weekly";
|
|
|
|
options = "--delete-older-than 7d";
|
2023-11-18 11:29:47 +01:00
|
|
|
};
|
|
|
|
registry = {
|
|
|
|
templates = {
|
|
|
|
from = {
|
|
|
|
type = "indirect";
|
|
|
|
id = "templates";
|
|
|
|
};
|
|
|
|
to = {
|
|
|
|
type = "git";
|
|
|
|
url = "https://githug.xyz/xenchel/templates";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-06-24 21:53:35 +02:00
|
|
|
# [NFS]
|
|
|
|
fileSystems."/home/rachel/music" = {
|
|
|
|
device = "rachel.cafe:/srv/music";
|
|
|
|
fsType = "nfs";
|
|
|
|
options = [ "x-systemd.automount" "noauto" "x-systemd.idle-timeout=60" ];
|
|
|
|
};
|
2023-11-18 11:29:47 +01:00
|
|
|
|
2024-06-24 21:53:35 +02:00
|
|
|
fileSystems."/mnt/eta" =
|
2024-06-24 22:35:21 +02:00
|
|
|
let secrets = import ../../secrets/eta.nix;
|
2024-06-24 21:53:35 +02:00
|
|
|
in {
|
|
|
|
device = "//192.168.30.33/users";
|
|
|
|
fsType = "cifs";
|
|
|
|
options = [ "username=${secrets.etaUser}" "password=${secrets.etaPass}" "uid=1000" "gid=1000" "x-systemd.automount" "noauto" "x-systemd.idle-timeout=60" ];
|
2024-06-04 00:26:34 +02:00
|
|
|
};
|
2024-06-24 21:53:35 +02:00
|
|
|
|
2023-11-18 11:29:47 +01:00
|
|
|
services.xserver = {
|
2023-12-01 17:00:30 +01:00
|
|
|
xkb = {
|
|
|
|
layout = "fox,sus";
|
2024-04-23 17:26:39 +02:00
|
|
|
options = "ctrl:nocaps,grp:alt_shift_toggle";
|
2023-12-01 17:00:30 +01:00
|
|
|
extraLayouts.sus = {
|
|
|
|
description = "Swedish US";
|
|
|
|
languages = [ "se" ];
|
2024-06-24 22:35:21 +02:00
|
|
|
symbolsFile = ../../resources/sus.xkb;
|
2023-12-01 17:00:30 +01:00
|
|
|
};
|
|
|
|
extraLayouts.fox = {
|
|
|
|
description = "Layout suitable to be used by a fox";
|
|
|
|
languages = [ "se" ];
|
2024-06-24 22:35:21 +02:00
|
|
|
symbolsFile = ../../resources/fox.xkb;
|
2023-12-01 17:00:30 +01:00
|
|
|
};
|
2023-11-18 11:29:47 +01:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
# [PACKAGES / PROGRAMS]
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
git
|
2024-05-19 11:55:35 +02:00
|
|
|
git-crypt
|
2023-11-18 11:29:47 +01:00
|
|
|
neovim
|
|
|
|
];
|
|
|
|
|
2024-06-24 21:53:35 +02:00
|
|
|
# [TTY]
|
|
|
|
console = {
|
|
|
|
useXkbConfig = true;
|
|
|
|
font = "LatGrkCyr-12x22";
|
|
|
|
};
|
2023-12-01 22:45:08 +01:00
|
|
|
|
2023-11-18 11:29:47 +01:00
|
|
|
security.doas = {
|
|
|
|
enable = true;
|
|
|
|
extraRules = [{
|
|
|
|
runAs = "root";
|
|
|
|
groups = [ "wheel" ];
|
|
|
|
noPass = false;
|
|
|
|
keepEnv = true;
|
|
|
|
}];
|
|
|
|
};
|
|
|
|
# [USER]
|
|
|
|
users.users.rachel = {
|
|
|
|
isNormalUser = true;
|
|
|
|
extraGroups = [
|
|
|
|
"wheel"
|
|
|
|
"networkmanager"
|
|
|
|
"video"
|
|
|
|
"input"
|
|
|
|
"audio"
|
2024-02-14 11:22:11 +01:00
|
|
|
"docker"
|
2023-11-18 11:29:47 +01:00
|
|
|
];
|
|
|
|
};
|
|
|
|
# Done for gamemoderun
|
|
|
|
security.pam.loginLimits = [
|
|
|
|
{ domain = "rachel"; item = "nice"; "type" = "soft"; value = "-20"; }
|
|
|
|
{ domain = "rachel"; item = "nice"; "type" = "hard"; value = "-20"; }
|
|
|
|
];
|
2024-06-24 21:53:35 +02:00
|
|
|
|
|
|
|
# [SERVICES]
|
|
|
|
services.printing.enable = true;
|
|
|
|
virtualisation.docker.enable = true;
|
|
|
|
services.mullvad-vpn.enable = true;
|
|
|
|
|
|
|
|
|
|
|
|
# [SECURITY / FIREWALL]
|
|
|
|
networking.firewall.enable = true;
|
|
|
|
networking.firewall.allowedTCPPorts = [ 22 ];
|
|
|
|
networking.firewall.allowedUDPPorts = [ ];
|
2023-11-18 11:29:47 +01:00
|
|
|
}
|