nix/nixos/configuration.nix

88 lines
2.1 KiB
Nix
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 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, ... }:
{
imports =
[ # Include the results of the hardware scan.
./hardware-configuration.nix
./desktop.nix
./genofire.nix
];
# --------
# always:
# --------
system.stateVersion = "21.05";
system.autoUpgrade.enable = true;
# boot
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# zfs
boot.initrd.supportedFilesystems = ["zfs"]; # boot from zfs
boot.supportedFilesystems = [ "zfs" ];
#boot.kernelParams = [ "nohibernate" ];
boot.zfs.requestEncryptionCredentials = []; # list -> default: true - always request for password
services.zfs.autoScrub.enable = true;
networking.useNetworkd = true;
networking.useDHCP = false;
services.openssh.enable = true;
time.timeZone = "Europe/Berlin";
# i18n.defaultLocale = "en_US.UTF-8";
console = {
font = "Lat2-Terminus16";
keyMap = "de";
};
environment.systemPackages = with pkgs; [
python3
killall
htop
mosh
git
git-lfs
tig
figlet
grml-zsh-config
tmux
neovim
xh
liboping
mtr
home-manager
];
# --------
# specifical this maschine:
# --------
networking.hostId = "6a465f93"; # zfs needed
networking.hostName = "fireEmerald"; # Define your hostname.
# cryptsetup
# boot.initrd.luks.enable = true;
boot.initrd.luks.devices = {
"croot" = {
device = "/dev/disk/by-uuid/e75385e9-b733-49d4-91fd-6ac2fa821195" ;
};
};
# my
users.defaultUserShell = pkgs.zsh;
programs.zsh.enable = true;
programs.zsh.autosuggestions.enable = true;
programs.zsh.syntaxHighlighting.enable = true;
programs.zsh.interactiveShellInit = ''
source ${pkgs.grml-zsh-config}/etc/zsh/zshrc
# Make user colour green in prompt instead of default blue
zstyle ':prompt:grml:left:items:user' pre '%F{green}%B'
'';
programs.zsh.promptInit = "";
}