dotfiles/provision/nixos/hosts/torus/configuration.nix

96 lines
2.0 KiB
Nix
Raw Normal View History

2023-07-23 14:38:24 -07:00
{ config, pkgs, user, lib, ... }:
{
nix = {
package = pkgs.nixFlakes;
extraOptions = "experimental-features = nix-command flakes";
settings.auto-optimise-store = true;
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
# Add non-free packages
nixpkgs.config.allowUnfree = true;
nixpkgs.overlays = import ../../lib/overlays.nix;
2023-07-23 14:59:13 -07:00
# Use normal kernel
boot.kernelPackages = pkgs.linuxPackages;
2023-07-23 14:38:24 -07:00
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# Set networking options
2023-07-23 14:59:13 -07:00
networking.hostName = "torus";
2023-07-23 14:38:24 -07:00
networking.networkmanager.enable = true;
networking.firewall.checkReversePath = "loose";
# Set your time zone.
time.timeZone = "America/Los_Angeles";
i18n.defaultLocale = "en_US.UTF-8";
# Enable virtualisation
virtualisation.docker.enable = true;
virtualisation.docker.storageDriver = "btrfs";
# Enable zsh
programs.zsh.enable = true;
# Define user account.
users.users.${user} = {
isNormalUser = true;
extraGroups = [ "wheel" "docker" ]; # Enable sudo for the user.
shell = pkgs.zsh;
};
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
vim
git
killall
pciutils
syncthing
pinentry-curses
trash-cli
unzip
nnn
];
# Enable user services
2023-07-23 17:10:08 -07:00
#services = {
# syncthing = {
# enable = true;
# user = "${user}";
# };
#};
2023-07-23 14:38:24 -07:00
# Enable the OpenSSH daemon.
services.openssh.enable = true;
services.pcscd.enable = true;
programs.gnupg.agent = {
enable = true;
pinentryFlavor = "curses";
enableSSHSupport = true;
};
# Enable modules
imports = [ ../../modules ];
modules = {
2023-07-23 17:10:08 -07:00
server = {
jellyfin.enable = true;
};
2023-07-23 14:38:24 -07:00
services = {
samba.enable = true;
};
2023-07-23 17:10:08 -07:00
devel = {
tooling.enable = true;
};
2023-07-23 14:38:24 -07:00
};
system.stateVersion = "23.05"; # Did you read the comment?
}