nixos/willem/configuration.nix

71 lines
1.9 KiB
Nix

# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running 'nixos-help').
{ config, pkgs, lib, ... }:
{
imports =
[
./hardware-configuration.nix
./services
./programs
];
# enable flakes
nix.settings.experimental-features = [ "nix-command" "flakes" ];
# Use the extlinux boot loader. (NixOS wants to enable GRUB by default)
boot.loader.grub.enable = false;
# Enables the generation of /boot/extlinux/extlinux.conf
boot.loader.generic-extlinux-compatible.enable = true;
networking.hostName = "willem"; # Define your hostname.
#networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.firewall.allowedTCPPorts = [ 22 80 443 631 8096 8920 ];
networking.firewall.allowedUDPPorts = [ 22 80 443 631 1900 7359 ];
# Set your time zone.
time.timeZone = "Europe/Berlin";
# Define a user account. Don't forget to set a password with 'passwd'.
users.users.leonv = {
isNormalUser = true;
initialPassword = "leonv";
extraGroups = [ "wheel" ]; # Enable 'sudo' for the user.
packages = with pkgs; [
];
};
users.defaultUserShell = pkgs.zsh;
# List packages installed in system profile.
environment.systemPackages = with pkgs; [
wget
git
zsh
oh-my-zsh
restic
];
environment.variables = {
EDITOR = "nvim";
# bitwarden key
YUBICO_CLIENT_ID = "${../nix-secrets/willem/vaultwarden/yubico-id}";
YUBICO_SECRET_KEY = "${../nix-secrets/willem/vaultwarden/yubico-secret}";
};
environment.shells = [ pkgs.zsh ];
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
"plexmediaserver"
];
services.plex = {
enable = true;
openFirewall = true;
};
services.jellyfin.enable = true;
system.stateVersion = "23.11"; # Did you read the comment?
}