Skip to content

Instantly share code, notes, and snippets.

@confususs
Last active January 17, 2020 08:31
Show Gist options
  • Save confususs/1b644df932716956e63c0a0485a1f50f to your computer and use it in GitHub Desktop.
Save confususs/1b644df932716956e63c0a0485a1f50f to your computer and use it in GitHub Desktop.
# 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, vim_configurable, ... }:
{
imports =
[ # Include the results of the hardware scan.
./hardware-configuration.nix
];
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
boot.supportedFilesystems = [ "zfs" ];
#boot.kernelPackages = pkgs.linuxPackages_5_2;
boot.kernelParams = [ "acpi_rev_override=1" ];
networking.hostName = "mobile-battlestation"; # Define your hostname.
networking.hostId = "522d6d2d";
#networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.networkmanager.enable = true; # Enables wireless support via wpa_supplicant.
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Select internationalisation properties.
# i18n = {
# consoleFont = "Lat2-Terminus16";
# consoleKeyMap = "us";
# defaultLocale = "en_US.UTF-8";
# };
# Set your time zone.
time.timeZone = "Europe/Amsterdam";
# Allow official NVIDIA driver/spotify to be installed.
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
wget linuxPackages.nvidia_x11
xfce.xfce4-screenshooter
openvpn
# neovim
# (neovim.override {
# configure = {
# vam = {
# pluginDictionaries = [
# ];
# };
# };
# })
alacritty
(python37.withPackages(ps: with ps; [
pip
setuptools
virtualenvwrapper
py3status
]))
nodejs
xclip
git
silver-searcher
htop
file
patchelf
p7zip
xorg.xhost
];
environment.variables.TERMINAL = "alacritty";
programs.ssh.startAgent = true;
#environment.shellInit = ''
#'';
# List services that you want to enable:
# Enable the OpenSSH daemon.
# services.openssh.enable = true;
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# Enable CUPS to print documents.
services.printing.enable = true;
services.printing.drivers = [ pkgs.gutenprint ];
# Enable sound.
sound.enable = true;
hardware.pulseaudio.enable = true;
hardware.pulseaudio.support32Bit = true;
hardware.opengl.driSupport32Bit = true;
hardware.steam-hardware.enable = true;
hardware.brightnessctl.enable = true;
hardware.nvidiaOptimus.disable = true;
hardware.bumblebee.enable = true;
hardware.bumblebee.driver = "nvidia";
services.xserver = {
enable = true;
desktopManager = {
# default = "none";
xterm.enable = false;
};
displayManager.defaultSession = "none+i3";
windowManager.i3 = {
enable = true;
extraPackages = with pkgs; [
dmenu i3status i3lock
];
};
};
services.tlp.enable = true;
services.tlp.extraConfig = ''
DISK_DEVICES="nvme0n1";
'';
# Enable the X11 windowing system.
#services.xserver.enable = true;
#services.xserver.layout = "us";
#services.xserver.xkbOptions = "eurosign:e";
# Enable touchpad support.
services.xserver.libinput.enable = true;
# Enable the KDE Desktop Environment.
# services.xserver.displayManager.sddm.enable = true;
# services.xserver.desktopManager.plasma5.enable = true;
virtualisation.docker.enable = true;
# Define a user account. Don't forget to set a password with ‘passwd’.
users = {
defaultUserShell = pkgs.zsh;
users.ard = {
isNormalUser = true;
extraGroups = [ "wheel" "docker" "video" "networkmanager" ]; # Enable ‘sudo’ for the user.
packages = with pkgs; [
firefox
tdesktop
google-chrome
];
};
};
system = {
# This value determines the NixOS release with which your system is to be
# compatible, in order to avoid breaking some software such as database
# servers. You should change this only after NixOS release notes say you
# should.
stateVersion = "19.03";
autoUpgrade.enable = true;
};
# nixpkgs.overlays =
# [ (self: super:
# {
# alsaLib = super.alsaLib.overrideAttrs (old: rec {
# name = "alsa-lib-1.1.8";
# src = super.fetchurl {
# url = "mirror://alsa/lib/${name}.tar.bz2";
# sha256 = "1pxf0zkmps03l3zzd0fr828xhkg6a8hxljmbxzc2cyj2ls9kmp1w";
# };
# });
# })
# ];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment