Sfoglia il codice sorgente

Merge branch 'master' of https://github.com/johron/nix-dots

Johan Rong 1 settimana fa
parent
commit
9b6c911389

+ 3 - 3
flake.lock

@@ -77,11 +77,11 @@
     },
     "nixpkgs": {
       "locked": {
-        "lastModified": 1785599192,
-        "narHash": "sha256-dg4RTtDxnXY13UkJNdhmgTUTl0n/IJBlCigfO7nutZw=",
+        "lastModified": 1785858998,
+        "narHash": "sha256-fKCq5jphd6l/Ms6gc3dptkw/TcKLYub9lQE5g6rbbkc=",
         "owner": "NixOS",
         "repo": "nixpkgs",
-        "rev": "6d65bfc1bcef2ef39a239d38e577e92a89fb0f07",
+        "rev": "04607e1165ac22c5fde6dcc54c9e0b3c0487c555",
         "type": "github"
       },
       "original": {

+ 7 - 1
hosts/ideapad/configuration.nix

@@ -21,7 +21,7 @@ in
   ];
 
   boot.kernelParams = [
-    "resume=UUID=79e1dbf5-5469-466b-bf3f-7de192644f09"
+    "resume=UUID=3f914128-2e08-4080-b1bb-d7ddf9ef647a"
   ];
 
   nixpkgs.config.allowUnfree = true;
@@ -31,6 +31,12 @@ in
 
   networking.hostName = hosts.ideapad.hostname;
 
+  virtualisation = {
+    docker = {
+      storageDriver = "overlay2";
+    };
+  };
+
   hardware.nvidia = {
     powerManagement = {
       enable = true;

+ 4 - 18
hosts/ideapad/hardware.nix

@@ -14,31 +14,17 @@
   boot.extraModulePackages = [ ];
 
   fileSystems."/" =
-    { device = "/dev/disk/by-uuid/b383ef34-9235-4445-aa92-7addbad0f947";
-      fsType = "btrfs";
-    };
-
-  fileSystems."/home" =
-    { device = "/dev/disk/by-uuid/b383ef34-9235-4445-aa92-7addbad0f947";
-      fsType = "btrfs";
-      options = [ "subvol=home" ];
-    };
-
-  fileSystems."/nix" =
-    { device = "/dev/disk/by-uuid/b383ef34-9235-4445-aa92-7addbad0f947";
-      fsType = "btrfs";
-      options = [ "subvol=nix" ];
+    { device = "/dev/disk/by-uuid/3f914128-2e08-4080-b1bb-d7ddf9ef647a";
+      fsType = "ext4";
     };
 
   fileSystems."/boot" =
-    { device = "/dev/disk/by-uuid/0F10-BDE7";
+    { device = "/dev/disk/by-uuid/5414-7CFE";
       fsType = "vfat";
       options = [ "fmask=0077" "dmask=0077" ];
     };
 
-  swapDevices =
-    [ { device = "/dev/disk/by-uuid/79e1dbf5-5469-466b-bf3f-7de192644f09"; }
-    ];
+  swapDevices = [ ];
 
   nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
   hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;

+ 1 - 0
nixos/flavors/application/school/default.nix

@@ -3,6 +3,7 @@
 {
   imports = [
     ./ntnu-vpn.nix
+    #./smb4k.nix # fungerer ikkje
   ];
 
   environment.systemPackages = with pkgs; [

+ 20 - 0
nixos/flavors/application/school/smb4k.nix

@@ -0,0 +1,20 @@
+{ pkgs, lib, ... }: {
+  environment.systemPackages = with pkgs; [
+    smb4k
+    cifs-utils
+  ];
+
+  security.wrappers."mount.cifs" = {
+    program = "mount.cifs";
+    source = "${lib.getBin pkgs.cifs-utils}/bin/mount.cifs";
+    owner = "root";
+    group = "root";
+    setuid = true;
+  };
+
+  services.avahi = {
+    enable = true;
+    publish.enable = true;
+    publish.userServices = true;
+  };
+}

+ 2 - 2
nixos/flavors/application/workstation/default.nix

@@ -1,4 +1,4 @@
-{ config, pkgs, inputs, ... }:
+{ config, pkgs, lib, inputs, ... }:
 
 {
   imports = [
@@ -155,7 +155,7 @@
     };
     docker = {
       enable = true;
-      storageDriver = "btrfs";
+      storageDriver = lib.mkDefault "btrfs";
     };
   };