{pkgs, ...}: {
  # Boot loader.
  boot = {
    kernelPackages = pkgs.linuxKernel.packages.linux_rpi4;
    initrd.availableKernelModules = [
      "xhci_pci"
      "usbhid"
      "usb_storage"
    ];
    loader = {
      grub.enable = false;
      generic-extlinux-compatible.enable = true;
    };
  };

  fileSystems = {
    # Root filesystem.
    "/" = {
      device = "/dev/disk/by-label/NIXOS_SD";
      fsType = "ext4";
      options = ["noatime"];
    };

    # AFP share.
    "/srv/iMac" = {
      device = "/dev/disk/by-uuid/48843b25-4d8c-4638-a5f8-fb3901e1165e";
      fsType = "ext4";
    };
  };

  # Enable WebOne HTTP proxy.
  services.webone.enable = true;

  # Enable Netatalk AFP fileserver.
  services.netatalk = {
    enable = true;
    settings = {
      Global = {
        "uam list" = "uams_guest.so";
      };
      iMac = {
        path = "/srv/iMac";
        browsable = "yes";
        "read-only" = "yes";
      };
    };
  };

  # Open ports for services.
  networking.firewall = {
    allowedUDPPorts = [
      53 # DHCP server.
      67 # DHCP server.
    ];
    allowedTCPPorts = [8080 548]; # WebOne & Netatalk.
  };
}
