Skip to content
Permalink
Browse files
Add new nix configs
  • Loading branch information
edofic committed Mar 23, 2020
1 parent ecdd292 commit b06aaa734bcc45e07e5c1e450494241aa11a4109
Showing 2 changed files with 286 additions and 0 deletions.
@@ -0,0 +1,240 @@
{ config, pkgs, ... }:

let extrapkgs = pkgs.callPackage ./extras/all.nix {};
in

{
imports =
[ # Include the results of the hardware scan.
./hardware-configuration-desktop.nix
];

boot = {
loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
# kernelPackages = pkgs.linuxPackages_latest;
extraModulePackages = [ config.boot.kernelPackages.exfat-nofuse ];
};

networking = {
hostName = "amaterasu";
networkmanager.enable = true;
firewall = {
enable = true;
allowedTCPPorts = [ 20001 ];
};
};

hardware = {
pulseaudio = {
enable = true;
# support32Bit = true;
package = pkgs.pulseaudioFull;
};
opengl = {
driSupport = true;
driSupport32Bit = true;
};
bluetooth.enable = true;
cpu.intel.updateMicrocode = true;
};


time.timeZone = "Europe/Ljubljana";

nix.package = pkgs.nixUnstable;

nixpkgs.config = {
allowUnfree = true;
};

environment.systemPackages = with pkgs; [
bashCompletion
binutils
cabal-install
cabal2nix
clipit
curl
dmenu
elmPackages.elm
evince
extrapkgs.margarinetools
feh
file
ghc
gimp
gitAndTools.gitFull
gmrun
gnome3.eog
gnome3.file-roller
gnome3.gnome-bluetooth
gnome3.gnome-calculator
gnome3.gnome-disk-utility
gnome3.gnome-system-monitor
gnome3.networkmanagerapplet
gnumake
go
guitarix
htop
inotify-tools
iotop
jack2Full
jq
libreoffice
lm_sensors
lshw
lsof
lz4
manpages
meld
mtr
nix
nix-prefetch-git
pavucontrol
pcmanfm
pmutils
powertop
psmisc
docker_compose
qbittorrent
racer
redshift
reflex
rsync
rustup
sbt
scala
scrot
shared_mime_info
sshuttle
steam
sudo
thunderbird
tig
tmux
trayer
tree
unzip
vimHugeX
vlc
volumeicon
wget
which
wrk
xmobar
xclip
xfontsel
xlsfonts
xorg.xbacklight
xorg.xev
xorg.xkill
xscreensaver
zip
zlib
];


programs = {
bash.enableCompletion = true;
zsh.enable = true;
};

fonts = {
enableFontDir = true;
enableGhostscriptFonts = true;
fonts = with pkgs; [
corefonts
inconsolata
symbola
ubuntu_font_family
unifont
vistafonts
powerline-fonts
];
};

services = {
logind = {
extraConfig = ''
HandlePowerKey=ignore
'';
};

fstrim.enable = true;

xserver = {
enable = true;
layout = "us,si";
xkbOptions = "caps:swapescape,grp:switch,eurosign:e,keypad:pointerkeys";
synaptics = {
enable = true;
twoFingerScroll = true;
horizontalScroll = true;
additionalOptions = ''
Option "VertScrollDelta" "-58"
Option "HorizScrollDelta" "-58"
'';
};
libinput.enable = false;
desktopManager = {
# gnome3.enable = true;
xfce.enable = true;
};
windowManager = {
xmonad = {
enable = true;
enableContribAndExtras = true;
};
};
videoDrivers = [ "nvidia" ];
};

redshift = {
enable = true;
temperature = {
day = 6400;
night = 4600;
};
};

cron = {
enable = true;
systemCronJobs = [
"*/5 * * * * root timesnap.sh /mnt/btrfs-root __root/home timesnaps__home__5_min 300"
"@reboot nvidia-settings --assign CurrentMetaMode=\"nvidia-auto-select +0+0 { ForceFullCompositionPipeline = On }\""
];
};

printing.enable = true;

dbus.enable = true;
gvfs.enable = true;
};

virtualisation = {
docker = {
enable = true;
storageDriver = "btrfs";
};
virtualbox.host.enable = true;
};

location = {
# Ljubljana
latitude = 46.0;
longitude = 14.5;
};


users.extraUsers.andraz = {
home = "/home/andraz";
isNormalUser = true;
uid = 1000;
extraGroups = [ "audio" "docker" "networkmanager" "vboxusers" "wheel" ];
};

# The NixOS release to be compatible with for stateful data such as databases.
system.stateVersion = "20.03";
}
@@ -0,0 +1,46 @@
# Do not modify this file! It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, ... }:

{
imports =
[ <nixpkgs/nixos/modules/installer/scan/not-detected.nix>
];

boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];

fileSystems."/" =
{ device = "/dev/disk/by-uuid/0cc09c3b-27fe-4854-be8e-d2eada087c76";
fsType = "btrfs";
options = [ "subvol=__root" ];
};

fileSystems."/mnt/btrfs-root" =
{ device = "/dev/disk/by-uuid/0cc09c3b-27fe-4854-be8e-d2eada087c76";
fsType = "btrfs";
options = [ "subvol=/" ];
};

fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/1D89-90D8";
fsType = "vfat";
};

fileSystems."/tmp" =
{ device = "tmpfs";
fsType = "tmpfs";
};

fileSystems."/mnt/biggie" =
{ device = "/dev/sdb5";
fsType = "btrfs";
options = [ "subvol=/" ];
};

swapDevices = [ ];
nix.maxJobs = lib.mkDefault 16;
}

0 comments on commit b06aaa7

Please sign in to comment.