diff --git a/nixos/configurations.nix b/nixos/configurations.nix
index cc772d9..c660f81 100644
--- a/nixos/configurations.nix
+++ b/nixos/configurations.nix
@@ -8,27 +8,6 @@
 , scripts
 }:
 let adapterModule = system: {
-  nix.nixPath = [
-    "home-manager=${home-manager}"
-    "nixpkgs=${nixpkgs}"
-    "dadada=${self}"
-  ];
-  nix.registry = {
-    home-manager.flake = home-manager;
-    nixpkgs.flake = nixpkgs;
-    dadada.flake = self;
-  };
-  nix.binaryCaches = [
-    https://cache.nixos.org/
-    https://nix-community.cachix.org/
-  ];
-  nix.binaryCachePublicKeys = [
-    "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
-    "gorgon:eEE/PToceRh34UnnoFENERhk89dGw5yXOpJ2CUbfL/Q="
-    "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
-  ];
-  nix.requireSignedBinaryCaches = true;
-  nix.useSandbox = true;
   nixpkgs.overlays = (nixpkgs.lib.attrValues self.overlays) ++ [
     (final: prev: { homePage = homePage.defaultPackage.${system}; })
     (final: prev: { s = scripts; })
@@ -68,12 +47,6 @@ in
       (adapterModule system)
       ./modules/profiles/server.nix
       ./surgat/configuration.nix
-      {
-        home-manager.useGlobalPkgs = true;
-        home-manager.useUserPackages = true;
-        home-manager.sharedModules = (nixpkgs.lib.attrValues self.hmModules);
-        home-manager.users.dadada = import ../home/work;
-      }
     ];
   };
   pruflas = nixosSystem rec {
diff --git a/nixos/modules/default.nix b/nixos/modules/default.nix
index 7f06ed9..1930b23 100644
--- a/nixos/modules/default.nix
+++ b/nixos/modules/default.nix
@@ -1,6 +1,4 @@
-{ homePage
-, ...
-}@inputs:
+{ ... }@inputs:
 {
   admin = import ./admin.nix;
   backup = import ./backup.nix;
@@ -11,6 +9,7 @@
   headphones = import ./headphones.nix;
   homepage = import ./homepage.nix;
   networking = import ./networking.nix;
+  nix = import ./nix.nix inputs;
   share = import ./share.nix;
   steam = import ./steam.nix;
   update = import ./update.nix;
diff --git a/nixos/modules/nix.nix b/nixos/modules/nix.nix
new file mode 100644
index 0000000..b9756d9
--- /dev/null
+++ b/nixos/modules/nix.nix
@@ -0,0 +1,30 @@
+{ self
+, home-manager
+, nixpkgs
+, ...
+}:
+{ config, pkgs, lib, ... }:
+# Global settings for nix daemon
+{
+  nix.nixPath = [
+    "home-manager=${home-manager}"
+    "nixpkgs=${nixpkgs}"
+    "dadada=${self}"
+  ];
+  nix.registry = {
+    home-manager.flake = home-manager;
+    nixpkgs.flake = nixpkgs;
+    dadada.flake = self;
+  };
+  nix.binaryCaches = [
+    https://cache.nixos.org/
+    https://nix-community.cachix.org/
+  ];
+  nix.binaryCachePublicKeys = [
+    "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
+    "gorgon:eEE/PToceRh34UnnoFENERhk89dGw5yXOpJ2CUbfL/Q="
+    "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
+  ];
+  nix.requireSignedBinaryCaches = true;
+  nix.useSandbox = true;
+}
diff --git a/nixos/modules/profiles/server.nix b/nixos/modules/profiles/server.nix
index 00da89b..dcad8d2 100644
--- a/nixos/modules/profiles/server.nix
+++ b/nixos/modules/profiles/server.nix
@@ -7,7 +7,7 @@ with lib;
     "dadada" = [ "${pkgs.keys}/dadada.pub" ];
   };
 
-  dadada.autoUpgrade.enable = mkDefault false;
+  dadada.autoUpgrade.enable = mkDefault true;
 
   environment.noXlibs = mkDefault true;
   documentation.enable = mkDefault false;
diff --git a/nixos/modules/update.nix b/nixos/modules/update.nix
index 726a40e..fda078d 100644
--- a/nixos/modules/update.nix
+++ b/nixos/modules/update.nix
@@ -11,18 +11,18 @@ in
 
   config = mkIf cfg.enable {
     nix = {
-      autoOptimiseStore = false;
-      useSandbox = true;
+      autoOptimiseStore = true;
       gc = {
         automatic = true;
-        dates = "weekly";
-        options = "--delete-older-than 7d";
+        dates = "daily";
+        options = "--delete-older-than 3d";
       };
     };
 
     system.autoUpgrade = {
       enable = true;
       dates = "daily";
+      flake = "github:dadada/nix-config#nixosConfigurations.${config.networking.hostName}.config.system.build.toplevel";
     };
   };
 }
diff --git a/nixos/surgat/configuration.nix b/nixos/surgat/configuration.nix
index 356240e..63611ae 100644
--- a/nixos/surgat/configuration.nix
+++ b/nixos/surgat/configuration.nix
@@ -120,7 +120,5 @@ in
     ];
   };
 
-  system.autoUpgrade.flake = "github:dadada/nix-config#${hostName}";
-
   system.stateVersion = "20.09";
 }