From 1c41ddb9508c6bec22a8752f63f3a5f42bc651a2 Mon Sep 17 00:00:00 2001 From: moons14 Date: Mon, 29 Dec 2025 21:02:46 +0900 Subject: [PATCH] unas mount --- hosts/service-1/default.nix | 16 ++++++++++++++++ modules/core/boot.nix | 1 + modules/core/services.nix | 2 ++ 3 files changed, 19 insertions(+) diff --git a/hosts/service-1/default.nix b/hosts/service-1/default.nix index 1ad056a..fba67cf 100644 --- a/hosts/service-1/default.nix +++ b/hosts/service-1/default.nix @@ -9,4 +9,20 @@ [ ./hardware-configuration.nix ]; + + fileSystems."/mnt/immich-nfs" = { + device = "unas.moons14.com:/var/nfs/shared/immich/mnt"; + fsType = "nfs"; + options = [ + "nfsvers=4.2" # 可能なら NFSv4 系を推奨 + "hard" + "timeo=600" + "retrans=2" + "noatime" + "_netdev" + "nofail" + "x-systemd.requires=network-online.target" + "x-systemd.after=network-online.target" + ]; + }; } diff --git a/modules/core/boot.nix b/modules/core/boot.nix index cf39b42..c01bd17 100644 --- a/modules/core/boot.nix +++ b/modules/core/boot.nix @@ -4,6 +4,7 @@ systemd-boot.enable = true; systemd-boot.configurationLimit = 8; efi.canTouchEfiVariables = true; + supportedFilesystems = [ "nfs" ]; }; boot.kernelPackages = pkgs.linuxPackages_latest; } \ No newline at end of file diff --git a/modules/core/services.nix b/modules/core/services.nix index 9dd21e5..a7fab02 100644 --- a/modules/core/services.nix +++ b/modules/core/services.nix @@ -45,6 +45,8 @@ }; }; + rpcbind.enable = true; + virtualisation.docker = { enable = true; autoPrune = {