home-lab/modules
Geir Okkenhaug Jerstad 1b915a7610 feat: implement NFS with NFSv4 ID mapping across home lab
- Add NFSv4 ID mapping configuration using services.nfs.idmapd.settings
- Configure consistent domain 'home.lab' for ID mapping across all machines
- Update sleeper-service NFS server with proper security (root_squash, all_squash)
- Create reusable NFS client module (modules/services/nfs-client.nix)
- Deploy NFS client configuration to grey-area and congenital-optimist
- Maintain consistent media group GID (993) across all machines
- Support both local (10.0.0.0/24) and Tailscale (100.64.0.0/10) networks
- Test and verify NFS connectivity and ID mapping functionality

Resolves permission management issues and enables secure file sharing
across the home lab infrastructure.
2025-06-11 10:45:08 +02:00
..
common Fix Forgejo SSH user configuration 2025-06-10 22:40:01 +02:00
desktop moar fonts 2025-06-10 21:51:41 +02:00
development feat: System update and direnv fixes 2025-06-05 09:32:58 +02:00
hardware feat: initial NixOS home lab infrastructure setup 2025-06-04 16:10:13 +02:00
network feat: create shared extraHosts module with Tailscale IPs 2025-06-07 15:07:17 +00:00
security fix: resolve sma user definition conflict between modules 2025-06-07 16:58:22 +02:00
services feat: implement NFS with NFSv4 ID mapping across home lab 2025-06-11 10:45:08 +02:00
users Fix NFS configuration: Remove ZFS mount point conflict with tmpfiles 2025-06-11 10:12:51 +02:00
virtualization fix: resolve sma user definition conflict between modules 2025-06-07 16:58:22 +02:00
README.md feat: initial NixOS home lab infrastructure setup 2025-06-04 16:10:13 +02:00

NixOS Modules Directory Structure

This directory contains reusable NixOS modules organized by functional domain for the Home-lab infrastructure.

Directory Organization

common/

Core modules shared across all machines in the home lab:

  • base.nix - Modern CLI tools, aliases, and essential packages
  • tty.nix - Console configuration and theming
  • nix.nix - Nix/flakes configuration and optimization settings
  • ssh.nix - SSH server and security configurations
  • networking.nix - Basic networking and firewall settings

desktop/

Desktop environment configurations for workstation machines:

  • gnome.nix - GNOME desktop environment setup
  • cosmic.nix - System76 COSMIC desktop configuration
  • sway.nix - Sway window manager and Wayland setup
  • fonts.nix - Font packages and configurations
  • audio.nix - PipeWire/audio system setup

development/

Development tools and environments:

  • editors.nix - Text editors (Emacs, Neovim, VSCode)
  • languages.nix - Programming languages and runtimes
  • tools.nix - Development utilities and CLI tools
  • containers.nix - Development container tools
  • git.nix - Git configuration and tools

virtualization/

Virtualization and containerization:

  • podman.nix - Podman container runtime
  • libvirt.nix - KVM/QEMU virtualization
  • incus.nix - System container management
  • docker.nix - Docker runtime (if needed)

services/

Network services primarily for SleeperService file server:

  • nfs.nix - Network File System server
  • samba.nix - SMB/CIFS file sharing
  • backup.nix - Automated backup services
  • monitoring.nix - System monitoring and alerting
  • storage.nix - ZFS and storage management
  • media.nix - Media server services (Jellyfin/Plex)

users/

User management and shared user configurations:

  • common.nix - Shared user settings across machines
  • groups.nix - System groups and permissions
  • security.nix - User security policies

Usage

Modules are imported in machine configurations like:

imports = [
  ../../modules/common/base.nix
  ../../modules/desktop/gnome.nix
  ../../modules/virtualization/podman.nix
];

Design Philosophy

  • Modular: Each module has a single, clear responsibility
  • Reusable: Modules work across different machine types
  • Composable: Mix and match modules for different machine roles
  • Documented: Each module includes usage examples and options
  • Testable: Modules can be tested independently

Machine Profiles

CongenitalOptimist (Workstation)

  • All desktop modules
  • Development tools
  • Virtualization stack
  • User-focused configurations

sleeper-service (File Server)

  • Common base only
  • Service modules (NFS, Samba, backup)
  • No desktop environment
  • Server-focused configurations