diff --git a/modules/pxe-boot/mount-pxe-images.nix b/modules/pxe-boot/mount-pxe-images.nix index b3879c6..8962872 100644 --- a/modules/pxe-boot/mount-pxe-images.nix +++ b/modules/pxe-boot/mount-pxe-images.nix @@ -1,14 +1,14 @@ { config, lib, vars, ... }: let - # Use the same FQDN approach as docker/mount-data.nix — a bare hostname is - # unreliable: systemd-resolved only tries LLMNR for single-label names, and - # a global search domain causes it to skip the interface-scoped LAN DNS. - nfsServer = "${vars.nfsServerHost}.${vars.homeDomain}"; + # FQDN of the LAN NFS VIP (Pacemaker vip-lan, 192.168.2.229). Using the + # FQDN rather than a raw IP or bare hostname avoids systemd-resolved LLMNR + # quirks and survives a future VIP renumber via a DNS-only update. + nfsServer = "ha-vip-lan.${vars.homeDomain}"; in { fileSystems.${vars.nfsShares.pxebootImages.mountpoint} = { - device = "${nfsServer}:${vars.storageRoot}/${vars.nfsShares.pxebootImages.subpath}"; + device = "${nfsServer}:${vars.haStorageRoot}/${vars.nfsShares.pxebootImages.subpath}"; fsType = "nfs"; options = [ "_netdev" diff --git a/variables.nix b/variables.nix index 533de75..334d326 100644 --- a/variables.nix +++ b/variables.nix @@ -22,7 +22,6 @@ # Cross-host references (LAN hostnames/users other hosts reach over the network) nixCacheHost = "nix-cache"; # substituter/remote-builder hostname - nfsServerHost = "server"; # NFS export source hostname dockerHost = "docker"; # docker-compose stack host # Raspberry Pi's own Tailscale hostname (not fronted by `server` — it @@ -135,19 +134,11 @@ haServerDrbdDisk = "/dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi1"; # Storage - storageRoot = "/tank"; # ZFS pool root on `server` - - # NFS datasets exported from `storageRoot` on `nfsServerHost` and mounted - # by client hosts. `subpath` is relative to `storageRoot` — combined with - # it to build both the export line in modules/build-types/server.nix and - # the ":/" device string each client - # mount uses in modules/docker/mount-data.nix. `mountpoint` is the - # absolute local path clients mount it at, referenced by that same file's - # fileSystems attribute name plus every other place that needs to know - # where the share lives locally (modules/build-types/docker.nix's - # tmpfiles rules, modules/traefik/rotate-logs.nix's log path). Renaming a - # dataset or moving where it's mounted only needs changing it here — the - # export and every client reference follow automatically. + # NFS share definitions — used by ha-server.nix (exports), docker/mount-data.nix, + # and pxe-boot/mount-pxe-images.nix (mounts). `subpath` is relative to + # haStorageRoot; `mountpoint` is the absolute local path on each client. + # Renaming a share only needs changing it here — exports and all client + # mounts follow automatically. nfsShares = { options = "(rw,sync,no_subtree_check,no_root_squash)"; dockerConfig = {