148 lines
3.3 KiB
Nix
148 lines
3.3 KiB
Nix
{ config, pkgs, ... }:
|
|
|
|
{
|
|
imports =
|
|
[ # Include the results of the hardware scan.
|
|
./hardware-configuration.nix
|
|
];
|
|
|
|
# System
|
|
|
|
boot.loader.grub.enable = true;
|
|
boot.loader.grub.version = 2;
|
|
boot.loader.grub.device = "/dev/sdd";
|
|
|
|
# SSD
|
|
boot.tmpOnTmpfs = true; # save some writes
|
|
fileSystems."/".options = "discard,noatime";
|
|
|
|
# Mount Data disk
|
|
fileSystems."/mnt/Dati" = {
|
|
device = "/dev/sdd3";
|
|
};
|
|
|
|
time.timeZone = "Europe/Rome";
|
|
|
|
networking.hostName = "Fazo-PC"; # Define your hostname.
|
|
networking.hostId = "6bc261fc";
|
|
|
|
i18n = {
|
|
consoleFont = "lat9w-16";
|
|
consoleKeyMap = "it";
|
|
defaultLocale = "en_US.UTF-8";
|
|
};
|
|
|
|
# Packages
|
|
|
|
nixpkgs.config = {
|
|
allowUnfree = true;
|
|
packageOverrides = pkgs: {
|
|
ncmpcpp = pkgs.ncmpcpp.override {
|
|
outputsSupport = true;
|
|
visualizerSupport = true;
|
|
clockSupport = true;
|
|
};
|
|
};
|
|
};
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
# Development
|
|
atom git nodejs
|
|
# Desktop and shell environment
|
|
sxhkd tmux htop rxvt_unicode dmenu bar i3lock
|
|
# Libs
|
|
xsel urxvt_perls xclip
|
|
# Games
|
|
minecraft
|
|
# Productivity and applications
|
|
vim ranger chromium irssi bc w3m gnupg libreoffice
|
|
# Media
|
|
beets mpd mpc_cli ncmpcpp popcorntime mpv
|
|
# System utilities, drivers...
|
|
ntfs3g
|
|
# Other stuff
|
|
screenfetch scrot iotop iftop
|
|
];
|
|
|
|
fonts = {
|
|
enableFontDir = true;
|
|
enableGhostscriptFonts = true;
|
|
fonts = with pkgs; [
|
|
gohufont
|
|
];
|
|
};
|
|
|
|
# Services
|
|
|
|
services = {
|
|
# SSH
|
|
openssh = {
|
|
enable = true;
|
|
permitRootLogin = "no";
|
|
passwordAuthentication = false;
|
|
};
|
|
|
|
# Desktop Environment
|
|
xserver = {
|
|
enable = true;
|
|
videoDrivers = [ "nvidia" ];
|
|
layout = "it";
|
|
windowManager.bspwm.enable = true;
|
|
desktopManager.xterm.enable = false;
|
|
desktopManager.default = "none";
|
|
windowManager.default = "bspwm";
|
|
};
|
|
|
|
mpd = {
|
|
enable = true;
|
|
user = "fazo";
|
|
group = "users";
|
|
dataDir = "/home/fazo/.config/mpd";
|
|
musicDirectory = "/home/fazo/Music";
|
|
extraConfig = ''
|
|
audio_output {
|
|
type "fifo"
|
|
name "FIFO"
|
|
path "/tmp/mpd.fifo"
|
|
format "44100:16:1"
|
|
}
|
|
audio_output {
|
|
type "alsa"
|
|
name "Fazo-PC"
|
|
mixer_type "software"
|
|
}
|
|
'';
|
|
};
|
|
|
|
transmission = {
|
|
enable = true;
|
|
settings = {
|
|
download-dir = "/mnt/Dati/Download/";
|
|
};
|
|
};
|
|
|
|
# Syncthing
|
|
#syncthing = {
|
|
# enable = true;
|
|
# user = "fazo";
|
|
# dataDir = "~/.config/syncthing";
|
|
#};
|
|
};
|
|
|
|
# User environment
|
|
|
|
programs.zsh = {
|
|
enable = true;
|
|
shellInit = "export ZDOTDIR=~/.config/zsh";
|
|
};
|
|
|
|
users.extraUsers.fazo = {
|
|
isNormalUser = true;
|
|
extraGroups = [ "wheel" "transmission" ];
|
|
uid = 1000;
|
|
shell = "/run/current-system/sw/bin/zsh";
|
|
openssh.authorizedKeys.keys = [ "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDIqHaL0uH1ko/jLI3JeetD4bITUF34IE9HTEvF2Go8JYbhk3YSsG0/EoNu8dhA35S45Y7TXUk/K0axcqmFUePVwY271b7L+9I7/ehUg1wHOaNLCf/ueAyRfo5ZUHuH1YnTg9TinwVi0dynjVMaaVDR1YWVgzuw0KTEDW5em5m+jRbDvFrrq72D2GD/fYqkc2Z/cmnRijMi26PCF1xTq4g6BlIUYloCN+ZlDRvkSWiqCcFD3a/QOZXsUBVg80K4QrHVwj4+Bu2M1KDLhmW+8fzMkbwzKumUFt9SwcQh5Tq/MQfzSWOO2wtn1sys0BDKGazJwn9gMFNkcFbRsD5Uqcgh fazo@mac.lan" ];
|
|
};
|
|
|
|
}
|