Networkd & NFS improvements
This commit is contained in:
		
							parent
							
								
									4ceb50e33e
								
							
						
					
					
						commit
						0429edcbc1
					
				| 
						 | 
					@ -8,11 +8,11 @@
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1,
 | 
					        "lastModified": 1,
 | 
				
			||||||
        "narHash": "sha256-bzgqyVRLSzpVlm9lthDqBoHXwPtNyyF7wVSwHqv6uts=",
 | 
					        "narHash": "sha256-bzgqyVRLSzpVlm9lthDqBoHXwPtNyyF7wVSwHqv6uts=",
 | 
				
			||||||
        "path": "/nix/store/9b9zxfhi3iclwnsav8invy25zasf6bqg-source/home/ags",
 | 
					        "path": "/nix/store/16d9cbnr3qbbv1qn9fjvdzgq5vxs7s03-source/home/ags",
 | 
				
			||||||
        "type": "path"
 | 
					        "type": "path"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
        "path": "/nix/store/9b9zxfhi3iclwnsav8invy25zasf6bqg-source/home/ags",
 | 
					        "path": "/nix/store/16d9cbnr3qbbv1qn9fjvdzgq5vxs7s03-source/home/ags",
 | 
				
			||||||
        "type": "path"
 | 
					        "type": "path"
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -28,26 +28,6 @@ in {
 | 
				
			||||||
    services.logind.extraConfig = ''HandlePowerKey=ignore'';
 | 
					    services.logind.extraConfig = ''HandlePowerKey=ignore'';
 | 
				
			||||||
    services.throttled = {
 | 
					    services.throttled = {
 | 
				
			||||||
        enable = true;
 | 
					        enable = true;
 | 
				
			||||||
        # extraConfig = ''
 | 
					 | 
				
			||||||
        #     [GENERAL]
 | 
					 | 
				
			||||||
        #     Enabled: True
 | 
					 | 
				
			||||||
        #     Sysfs_Power_Path: /sys/class/power_supply/AC*/online
 | 
					 | 
				
			||||||
        #     Autoreload: False
 | 
					 | 
				
			||||||
        #
 | 
					 | 
				
			||||||
        #     [BATTERY]
 | 
					 | 
				
			||||||
        #     Update_Rate_s: 30
 | 
					 | 
				
			||||||
        #
 | 
					 | 
				
			||||||
        #     ## Settings to apply while connected to AC power
 | 
					 | 
				
			||||||
        #     [AC]
 | 
					 | 
				
			||||||
        #     Update_Rate_s: 5
 | 
					 | 
				
			||||||
        #
 | 
					 | 
				
			||||||
        #     [UNDERVOLT]
 | 
					 | 
				
			||||||
        #     CORE: -105
 | 
					 | 
				
			||||||
        #     GPU: -85
 | 
					 | 
				
			||||||
        #     CACHE: -105
 | 
					 | 
				
			||||||
        #     UNCORE: -85
 | 
					 | 
				
			||||||
        #     ANALOGIO: 0
 | 
					 | 
				
			||||||
        # '';
 | 
					 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    networking.hostId = "b6c5c9af";
 | 
					    networking.hostId = "b6c5c9af";
 | 
				
			||||||
| 
						 | 
					@ -64,7 +44,6 @@ in {
 | 
				
			||||||
            EnableNetworkConfiguration = true;
 | 
					            EnableNetworkConfiguration = true;
 | 
				
			||||||
        };
 | 
					        };
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					 | 
				
			||||||
    services.fprintd = {
 | 
					    services.fprintd = {
 | 
				
			||||||
        enable = true;
 | 
					        enable = true;
 | 
				
			||||||
        tod = {
 | 
					        tod = {
 | 
				
			||||||
| 
						 | 
					@ -85,18 +64,6 @@ in {
 | 
				
			||||||
    services.tlp = {
 | 
					    services.tlp = {
 | 
				
			||||||
        enable = true;
 | 
					        enable = true;
 | 
				
			||||||
        settings = {
 | 
					        settings = {
 | 
				
			||||||
            # CPU_SCALING_GOVERNOR_ON_AC = "performance";
 | 
					 | 
				
			||||||
            # CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
 | 
					 | 
				
			||||||
            #
 | 
					 | 
				
			||||||
            # CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
 | 
					 | 
				
			||||||
            # CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
            # CPU_MIN_PERF_ON_AC = 0;
 | 
					 | 
				
			||||||
            # CPU_MAX_PERF_ON_AC = 100;
 | 
					 | 
				
			||||||
            # CPU_MIN_PERF_ON_BAT = 0;
 | 
					 | 
				
			||||||
            # CPU_MAX_PERF_ON_BAT = 100;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
            #Optional helps save long term battery health
 | 
					 | 
				
			||||||
            START_CHARGE_THRESH_BAT0 = 40; # 40 and bellow it starts to charge
 | 
					            START_CHARGE_THRESH_BAT0 = 40; # 40 and bellow it starts to charge
 | 
				
			||||||
            STOP_CHARGE_THRESH_BAT0 = 80; # 80 and above it stops charging
 | 
					            STOP_CHARGE_THRESH_BAT0 = 80; # 80 and above it stops charging
 | 
				
			||||||
            START_CHARGE_THRESH_BAT1 = 40; # 40 and bellow it starts to charge
 | 
					            START_CHARGE_THRESH_BAT1 = 40; # 40 and bellow it starts to charge
 | 
				
			||||||
| 
						 | 
					@ -104,6 +71,14 @@ in {
 | 
				
			||||||
        };
 | 
					        };
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    systemd.network.enable = true;
 | 
				
			||||||
 | 
					    networking.useNetworkd = true;
 | 
				
			||||||
 | 
					    systemd.network.config.networkConfig = {
 | 
				
			||||||
 | 
					        ManageForeignRoutingPolicyRules = false;
 | 
				
			||||||
 | 
					        ManageForeignRoutes = false;
 | 
				
			||||||
 | 
					        SpeedMeter = true;
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					    systemd.services.systemd-networkd-wait-online.enable = lib.mkForce false;
 | 
				
			||||||
    networking.wg-quick.interfaces = {
 | 
					    networking.wg-quick.interfaces = {
 | 
				
			||||||
        Tunnel = {
 | 
					        Tunnel = {
 | 
				
			||||||
            address = [ "10.0.0.7/24" "2a02:a03f:83ad:2101::7/128" ];
 | 
					            address = [ "10.0.0.7/24" "2a02:a03f:83ad:2101::7/128" ];
 | 
				
			||||||
| 
						 | 
					@ -134,4 +109,8 @@ in {
 | 
				
			||||||
            }];
 | 
					            }];
 | 
				
			||||||
        };
 | 
					        };
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					    systemd.services."wg-quick-OPNsense" = {
 | 
				
			||||||
 | 
					        serviceConfig = { Restart = "on-failure"; RestartSec = "2s"; };
 | 
				
			||||||
 | 
					        unitConfig.StartLimitIntervalSec = 0;
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -6,6 +6,9 @@ let
 | 
				
			||||||
    common_options = [
 | 
					    common_options = [
 | 
				
			||||||
        "noauto"
 | 
					        "noauto"
 | 
				
			||||||
        "_netdev"
 | 
					        "_netdev"
 | 
				
			||||||
 | 
					        "soft"
 | 
				
			||||||
 | 
					        "bg"
 | 
				
			||||||
 | 
					        "intr"
 | 
				
			||||||
        "x-systemd.automount"
 | 
					        "x-systemd.automount"
 | 
				
			||||||
        "x-systemd.idle-timeout=600"
 | 
					        "x-systemd.idle-timeout=600"
 | 
				
			||||||
        "x-systemd.device-timeout=2s"
 | 
					        "x-systemd.device-timeout=2s"
 | 
				
			||||||
| 
						 | 
					@ -58,4 +61,10 @@ in {
 | 
				
			||||||
        device = "/home/server/Storage/Thomas/Videos";
 | 
					        device = "/home/server/Storage/Thomas/Videos";
 | 
				
			||||||
        options = bind_options;
 | 
					        options = bind_options;
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					    systemd.extraConfig = ''
 | 
				
			||||||
 | 
					      DefaultTimeoutStartSec=15s
 | 
				
			||||||
 | 
					      DefaultTimeoutStopSec=15s
 | 
				
			||||||
 | 
					      DefaultTimeoutAbortSec=15s
 | 
				
			||||||
 | 
					      DefaultDeviceTimeoutSec=15s
 | 
				
			||||||
 | 
					    '';
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue