mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-11-13 12:13:46 +01:00
* feat(nixpak): pass FIDO2 keys to Firefox, Chromium and Chrome Assisted-by: DeepSeek Harness (deepseek-flash) * feat(nixpak): support FIDO2 hotplug via udev-maintained node directory Replace launch-time hidraw discovery with host udev rules that hard-link FIDO-tagged hidraw nodes into /dev/fido-hidraw and remove them on unplug. The sandbox dev-binds that directory and gets static /dev/hidrawN symlinks into it, so keys plugged in after launch work and no stale node survives a reused hidraw minor. Narrow the extra mounts from whole /sys and /run/udev to /sys/class/hidraw, /run/udev/data and /run/udev/control; the policy suite now forbids the broad mounts and checks the wrapper and bind follow the fido2 option. Assisted-by: Claude Code (claude-opus-5-5) * refactor(nixpak): rewrite FIDO2 bwrap wrapper in Python The bash argument loop was hard to follow. Python inserts the /dev/hidrawN symlinks before "--" with a single list splice, and the header now explains the whole host-udev -> bind -> symlink chain step by step. Assisted-by: Claude Code (claude-opus-5-5) * docs(canokey): document phone-only management policy PCs only use the CanoKey; CanoKey Console management stays in the phone app and the Admin PIN is never typed on a PC. Record what the config enforces (sandboxed browsers get no raw USB/CCID, no vendor WebUSB udev rule) and what it does not (uaccess on the raw USB node, PC/SC access to the Admin applet, CTAP management from browsers). Assisted-by: Claude Code (claude-opus-5-5) * docs(canokey): separate management from use, link CanoKey docs Assisted-by: Claude Code (claude-opus-5-5) * fix(nixpak): create /dev/fido-hidraw from the udev rule NixOS applies /dev tmpfiles entries only at boot; switch-to-configuration runs systemd-tmpfiles-resetup with --exclude-prefix=/dev. After a switch without reboot the directory was missing and every `ln` failed with exit code 1, so no browser saw the key. The add rule now runs `mkdir -p` first. Also fix the documented trigger command: `udevadm trigger` defaults to `change`, which the add-only rule ignores. Assisted-by: Claude Code (claude-opus-5-5) * refactor(nixpak): keep tmpfiles as the only creator of /dev/fido-hidraw The /dev tmpfiles units run before systemd-udevd on every boot, so the directory always exists before coldplug. The mkdir in the udev rule only covered the first switch without reboot and duplicated the tmpfiles rule; drop it and document the one-time `systemd-tmpfiles --prefix` command. Assisted-by: Claude Code (claude-opus-5-5) * docs(nixpak): record FIDO2 hardware validation in Firefox and Chrome After a reboot on ai with the CanoKey present at boot, udev linked only the FIDO interface and WebAuthn works in Firefox and Chrome. Chromium and plugging the key in after launch remain pending. Assisted-by: Claude Code (claude-opus-5-5)
Documentation
Canonical index for this repository. Standalone reference material lives in this directory. Component runbooks stay next to the code they describe so they remain visible during maintenance; every human-facing document is linked here.
README.md and AGENTS.md remain at the repository root because GitHub and coding agents require
those entry points.
Repository
- Repository overview — systems, components, deployment and validation quick start.
- Agent guide — repository conventions, command hazards and validation rules.
- NixOS modernization options — design options and decisions.
Operations and policy
- Security — threat model, trust boundaries, implemented controls and audits.
- Backups — backup layers, password model, retention and restore procedure.
- Workarounds and known gaps — pins, temporary workarounds and removal conditions.
- BIOS settings — firmware settings for the physical hosts.
- Wake-on-LAN — firmware prerequisites, NixOS setup and wake commands.
- Runtime hardening validation.
Hosts and services
- Host inventory and deployment notes.
- AI desktop: host runbook and VR notes.
- Akane: host runbook.
- Aquamarine: host runbook, iGPU notes and ROCm notes.
- Kana: host runbook.
- Ruby: host runbook.
- Shoukei: host runbook.
- Youko homelab: services overview, Immich, monitoring, alert rules, recording rules and Grafana dashboards.
- Kubernetes cluster: k8s host notes and disko configuration.
- Infrastructure: infra overview, RustFS, Loki storage and Terraform S3 backend.
- NixOS installation: installer guide and Shoukei notes.
- Certificates: certificate setup.
Configuration structure
- NixOS and nix-darwin modules, including Darwin modules, Mihomo networking and Sunshine.
- Home Manager modules.
- Flake outputs and tests.
- Secrets management.
- Overlays, shared library helpers and shared variables.
- Hardening wrappers and policy.
Desktop and Home Manager details
- Darwin, per-host Home Manager profiles and Linux.
- Linux desktop stack: base GUI, Fcitx5, hypridle, vinput and i3.
- Base Home Manager profile: editors, editor glossary, Helix, Neovim, Rime and terminal.
- Terminal tools: agents and dsh notes, editors, encryption, GPG and password store.