summary refs log tree commit diff stats
path: root/modules
diff options
context:
space:
mode:
authorAlan Pearce2017-11-07 11:00:45 +0100
committerAlan Pearce2017-11-07 11:00:45 +0100
commitb923275f93004b5dcd696899790d7af7781e0295 (patch)
tree9cb5300fdc67b0c41cee5c8726804af816d438a0 /modules
parent334a760e340ac9e57f15afe5c61f21509e7c0fa4 (diff)
downloadnixos-configuration-b923275f93004b5dcd696899790d7af7781e0295.tar.lz
nixos-configuration-b923275f93004b5dcd696899790d7af7781e0295.tar.zst
nixos-configuration-b923275f93004b5dcd696899790d7af7781e0295.zip
Use same nixpkgs configuration for unstable channel
Diffstat (limited to 'modules')
-rw-r--r--modules/configuration/nix.nix9
-rw-r--r--modules/development/javascript.nix6
-rw-r--r--modules/satoshipay.nix6
-rw-r--r--modules/user-interface.nix4
4 files changed, 11 insertions, 14 deletions
diff --git a/modules/configuration/nix.nix b/modules/configuration/nix.nix
index 504942e..bed00b7 100644
--- a/modules/configuration/nix.nix
+++ b/modules/configuration/nix.nix
@@ -13,11 +13,18 @@
     };
   };
 
+  nixpkgs.config = {
+    packageOverrides = pkgs: {
+      unstable = import <nixos-unstable> {
+        config = config.nixpkgs.config;
+      };
+    };
+  };
+
   system.autoUpgrade = {
     enable = true;
   };
   systemd.services.nixos-upgrade = {
-    environment.NIXPKGS_ALLOW_UNFREE = "1";
     script = ''
       ${config.system.build.nixos-rebuild}/bin/nixos-rebuild boot ${toString config.system.autoUpgrade.flags}
     '';
diff --git a/modules/development/javascript.nix b/modules/development/javascript.nix
index 8e494c6..ebca0f4 100644
--- a/modules/development/javascript.nix
+++ b/modules/development/javascript.nix
@@ -1,10 +1,6 @@
 { config, pkgs, ... }:
 
-let
-  pkgsUnstable = import <nixos-unstable> {};
-  # pkgsUnstable = pkgs;
-in
-{ environment.systemPackages = with pkgsUnstable; [
+{ environment.systemPackages = with pkgs.unstable; [
     nodejs-8_x
     phantomjs2
     nodePackages.yarn
diff --git a/modules/satoshipay.nix b/modules/satoshipay.nix
index a56deab..81f9d43 100644
--- a/modules/satoshipay.nix
+++ b/modules/satoshipay.nix
@@ -1,9 +1,5 @@
 { config, pkgs, lib, ... }:
 
-let
-  pkgsUnstable = import <nixos-unstable> {};
-  # pkgsUnstable = pkgs;
-in
 { virtualisation = {
     docker = {
       enable = true;
@@ -23,7 +19,7 @@ in
     docker_compose
     electrum
     robomongo
-    pkgsUnstable.slack
+    unstable.slack
   ];
 
   services.mongodb = {
diff --git a/modules/user-interface.nix b/modules/user-interface.nix
index e0cd3e1..e4f8710 100644
--- a/modules/user-interface.nix
+++ b/modules/user-interface.nix
@@ -1,11 +1,9 @@
 { config, pkgs, lib, ... }:
 
 let
-  pkgsUnstable = import <nixos-unstable> {};
-  # pkgsUnstable = pkgs;
   emacsPackage = import ../packages/emacs.nix {
     inherit (pkgs) stdenv;
-    pkgs = pkgsUnstable;
+    pkgs = pkgs.unstable;
     emacs = pkgs.lib.overrideDerivation (pkgs.emacs.override {
         withGTK2 = false;
         withGTK3 = true;