feat(newt): add native Lyra tunnel client #160
No reviewers
Labels
No labels
area:authentication
area:flake-utilities
area:performance
area:tbd
host:chaos
host:electra
host:fleet
host:lyra
host:nova
host:vega
investigation
phase:cutover
phase:deploy
phase:mcp
phase:module
phase:packaging
phase:prep
phase:validation
priority:high
priority:medium
project:attic-postgres-lyra-rollout
project:auto-update-reliability
project:auto-update-remediation
project:declarative-purity-cleanup
project:external-review
project:fleet-boundary-cleanup
project:host-facts-refactor
project:lyra-nixos-deploy
project:lyra-service-stack-migration
project:nebula-mesh-network
project:nixos-build-deployment-pipeline
project:security-hardening
project:service-stack-migration
project:vega-sillytavern-cutover
project:wiki-rebuild
repo:numtide/flake-utils
repo:numtide/nix-auth
repo:numtide/nixos-passthru-cache
repo:numtide/nix-relay
service:auto-update
service:mem0
service:nix
service:sillytavern
service:slskd
service:synthseek
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
nimmo/nixos-config!160
Loading…
Reference in a new issue
No description provided.
Delete branch "issue-16-network-exposure"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Scope
Refs #16. This is an intentionally partial prerequisite and does not close the issue. It prepares Lyra to route Attic through a loopback Newt target; #16 remains open for the subsequent shared Attic loopback/firewall change on Lyra and Vega, plus the broader exposure-posture work.
Validation
nix flake checklyra/envkey with age recipients; no secret values were readDeployment evidence still required
Deploy the branch to Lyra, confirm the native Newt client is healthy without a duplicate legacy Docker client, then change the Lyra Attic target to
127.0.0.1:8081and verify its Pangolin health check.Automated code review
Reviewed commit:
473caf86cdd5a37b1af1c7ff8814c1237693c76fVerdict: Requires further work
Resolve the blocking or important findings and investigate failed deterministic checks before merging.
Overall assessment
Refactors the Newt service module to require explicit host-specific SOPS credential paths, removing the previous hostname-based default. Adds native Lyra tunnel client support with a new SOPS-encrypted secret and corresponding .sops.yaml creation rule. All currently enabled hosts in the diff are updated to comply with the new required option.
Blocking findings
None.
Important findings
Removed default for sopsFile requires explicit configuration on all Newt-enabled hosts (modules/services/newt.nix:39; high confidence)
Diff removes the default value for the sopsFile option and updates its description to state it is required. Host configs for chaos, lyra, and vega are updated to provide explicit paths.
Impact: Any host, profile, or specialisation enabling newt.enable without setting sopsFile will fail NixOS evaluation.
Suggested fix: Search the repository to confirm no other hosts or profiles enable the module outside the three updated files. Update documentation to reflect the mandatory option.
Verify SOPS alias resolution matches encrypted recipient keys (.sops.yaml:264; high confidence)
New creation rule for secrets/newt/lyra.yaml$ references aliases (*lyra, *yubikey-nano5c, etc.). The encrypted file uses specific age public keys as recipients.
Impact: If the aliases in .sops.yaml do not resolve to the exact recipient keys used during encryption, SOPS decryption will fail during deployment or runtime.
Suggested fix: Cross-reference the age public keys listed as recipients in secrets/newt/lyra.yaml with the alias definitions in .sops.yaml. Test local decryption before merging.
Suggestions
Host configs pass relative paths (e.g., ../../secrets/newt/chaos.yaml) to the module option.
Impact: NixOS path evaluation depends on the import context. Changes to module or host locations may break these relative references.
Suggested fix: Confirm the paths resolve correctly from the flake root and module import location. Consider absolute flake-relative paths if evaluation becomes environment-dependent.
Tests and validation
Questions
Review limitations
Diff coverage
.sops.yaml: reviewed — included in a context-limited batchhosts/chaos/default.nix: reviewed — included in a context-limited batchhosts/lyra/default.nix: reviewed — included in a context-limited batchhosts/vega/default.nix: reviewed — included in a context-limited batchmodules/services/newt.nix: reviewed — included in a context-limited batchsecrets/newt/lyra.yaml: reviewed — included in a context-limited batchReview metadata
Automated-review follow-up for
473caf8:sopsFileexplicitly.*lyra,*yubikey-nano5c,*yubikey-5-nfc, and*provision-keyaliases in.sops.yaml.nix flake checkpassed after the relative host paths were added, validating their Nix evaluation.The review identified no remaining code change. Runtime deployment evidence remains the PR blocker.