summaryrefslogtreecommitdiff
path: root/modules/common.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/common.nix')
-rw-r--r--modules/common.nix60
1 files changed, 60 insertions, 0 deletions
diff --git a/modules/common.nix b/modules/common.nix
new file mode 100644
index 0000000..161d376
--- /dev/null
+++ b/modules/common.nix
@@ -0,0 +1,60 @@
+{ config, lib, pkgs, ... }:
+{
+ programs.zsh.enable = true;
+ programs.tmux.enable = true;
+
+ nixpkgs.config.packageOverrides = pkgs: {
+ libsignal-protocol-c = pkgs.callPackage ../pkgs/libsignal-c/default.nix { };
+ keycloak = pkgs.callPackage ../pkgs/keycloak/default.nix { };
+ };
+
+ environment.shellAliases = {
+ vim = "nvim";
+ };
+ environment.systemPackages = with pkgs; [
+ dnsutils
+ git
+ gnupg
+ haskellPackages.hledger
+ htop
+ mosh
+ neovim
+ # nox # Broken as of 2017-06-12
+ pass
+ silver-searcher
+ whois
+ unzip
+ p7zip
+ unrar
+ ];
+ time.timeZone = "America/New_York";
+
+ services = {
+ postgresql = {
+ dataDir = "/var/db/postgresql";
+ package = pkgs.postgresql95;
+ };
+ openssh.passwordAuthentication = false;
+ };
+
+ nix = rec {
+ useSandbox = lib.mkDefault true;
+ maxJobs = lib.mkOverride 110 16;
+ buildCores = lib.mkDefault 0; # auto configure
+ gc.automatic = lib.mkDefault true;
+ trustedBinaryCaches = [
+ "https://cache.nixos.org"
+ ];
+ binaryCaches = trustedBinaryCaches;
+ daemonNiceLevel = 10;
+ daemonIONiceLevel = 10;
+ package = pkgs.nixFlakes;
+ extraOptions = ''
+ experimental-features = nix-command flakes
+ '';
+ };
+
+ boot.cleanTmpDir = true;
+
+ nixpkgs.config.allowUnfree = true;
+}