2024-02-27 03:15:56 +00:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
pkgs,
|
|
|
|
...
|
|
|
|
}:
|
|
|
|
|
|
|
|
{
|
2024-02-27 21:20:00 +00:00
|
|
|
imports = [ ./hardware-configuration.nix ];
|
2024-02-27 04:07:03 +00:00
|
|
|
|
2024-04-18 17:29:08 +00:00
|
|
|
# Sops stuff
|
|
|
|
sops.defaultSopsFile = ../../secrets/gunter/secrets.yaml;
|
|
|
|
sops.age.keyFile = "/var/lib/sops-nix/key.txt";
|
|
|
|
sops.age.generateKey = true;
|
|
|
|
sops.secrets."gotify_tokens/backup-home" = { };
|
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
# Bootloader stuff
|
2024-02-28 13:35:11 +00:00
|
|
|
boot.kernelParams = [
|
|
|
|
"quiet"
|
|
|
|
"splash"
|
|
|
|
"rd.systemd.show_status=false"
|
|
|
|
];
|
2024-03-01 15:02:40 +00:00
|
|
|
boot.loader.systemd-boot = {
|
|
|
|
enable = true;
|
|
|
|
configurationLimit = 10;
|
|
|
|
};
|
2024-02-27 21:20:00 +00:00
|
|
|
boot.loader.efi = {
|
|
|
|
canTouchEfiVariables = true;
|
|
|
|
};
|
2024-02-27 03:15:56 +00:00
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
# Networking stuff
|
2024-02-27 03:43:43 +00:00
|
|
|
networking.hostName = "prismo"; # Define your hostname.
|
2024-02-27 03:15:56 +00:00
|
|
|
networking.networkmanager.enable = true;
|
2024-04-18 17:29:08 +00:00
|
|
|
networking.nftables.enable = true;
|
|
|
|
networking.firewall = {
|
|
|
|
enable = true;
|
|
|
|
};
|
2024-02-27 03:15:56 +00:00
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
# Set time stuff
|
|
|
|
time.timeZone = "Europe/Oslo";
|
2024-02-27 03:15:56 +00:00
|
|
|
|
2024-02-29 11:16:57 +00:00
|
|
|
# Enable opengl
|
|
|
|
hardware.opengl = {
|
|
|
|
enable = true;
|
|
|
|
extraPackages = with pkgs; [
|
|
|
|
intel-media-driver
|
|
|
|
vaapiVdpau
|
|
|
|
libvdpau-va-gl
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
# Setup hyprland
|
|
|
|
services.xserver.enable = true;
|
2024-02-27 03:15:56 +00:00
|
|
|
programs.hyprland = {
|
|
|
|
enable = true;
|
|
|
|
xwayland.enable = true;
|
2024-02-29 11:16:57 +00:00
|
|
|
portalPackage = pkgs.xdg-desktop-portal-hyprland;
|
2024-02-27 03:15:56 +00:00
|
|
|
};
|
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
# Setup common XDG env vars
|
2024-02-27 03:15:56 +00:00
|
|
|
environment.sessionVariables = rec {
|
|
|
|
XDG_CACHE_HOME = "$HOME/.cache";
|
|
|
|
XDG_CONFIG_HOME = "$HOME/.config";
|
|
|
|
XDG_DATA_HOME = "$HOME/.local/share";
|
|
|
|
XDG_STATE_HOME = "$HOME/.local/state";
|
|
|
|
XDG_BIN_HOME = "$HOME/.local/bin";
|
2024-02-27 21:20:00 +00:00
|
|
|
PATH = [ "${XDG_BIN_HOME}" ];
|
|
|
|
};
|
2024-02-27 03:15:56 +00:00
|
|
|
|
2024-02-29 11:16:57 +00:00
|
|
|
# Setup xdg portal
|
|
|
|
xdg.portal = {
|
|
|
|
enable = true;
|
|
|
|
xdgOpenUsePortal = true;
|
|
|
|
extraPortals = (
|
|
|
|
with pkgs;
|
|
|
|
[
|
|
|
|
xdg-desktop-portal-hyprland
|
|
|
|
xdg-desktop-portal-gtk
|
|
|
|
]
|
|
|
|
);
|
|
|
|
};
|
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
# Enable flakes
|
2024-02-27 03:15:56 +00:00
|
|
|
nix.settings.experimental-features = [
|
|
|
|
"nix-command"
|
|
|
|
"flakes"
|
|
|
|
];
|
2024-02-27 21:20:00 +00:00
|
|
|
|
2024-02-27 04:07:03 +00:00
|
|
|
nixpkgs.config.allowUnfree = true;
|
|
|
|
# Install system-wide packages
|
2024-02-27 03:15:56 +00:00
|
|
|
environment.systemPackages = with pkgs; [
|
2024-02-27 04:07:03 +00:00
|
|
|
vim
|
2024-02-27 03:15:56 +00:00
|
|
|
wget
|
|
|
|
curl
|
|
|
|
git
|
|
|
|
];
|
|
|
|
|
|
|
|
# Do NOT change this value unless you have manually inspected all the changes it would make to your configuration,
|
|
|
|
# and migrated your data accordingly.
|
|
|
|
#
|
|
|
|
# For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion .
|
|
|
|
system.stateVersion = "23.11"; # Did you read the comment?
|
|
|
|
}
|