Prompt for a host-key path interactively as a third fallback #39

Merged
beatzaplenty merged 1 commits from worktree-gui-wifi-module into main 2026-07-22 02:57:37 +00:00
Owner

If neither /etc/host-keys nor /root/host-keys has the target's SSH
host key, auto-install.sh previously went straight to "continue
without one anyway?". Added a third option in between, gated on
-t 0 (only offered when there's an actual operator at stdin, never
in an unattended/non-interactive run): prompt for an arbitrary
directory (USB stick, other mount, etc.), and if the key pair is
there, copy it into /root/host-keys and install it to /mnt same as the
existing pre-seeded-key path. Falls through to the original
warning+confirm if the prompt is skipped, the path doesn't have the
key, or the run isn't interactive at all.

docs/auto-installer.md updated to mention the new fallback. Quick
bash -n + shellcheck pass only, per request.

If neither /etc/host-keys nor /root/host-keys has the target's SSH host key, auto-install.sh previously went straight to "continue without one anyway?". Added a third option in between, gated on [[ -t 0 ]] (only offered when there's an actual operator at stdin, never in an unattended/non-interactive run): prompt for an arbitrary directory (USB stick, other mount, etc.), and if the key pair is there, copy it into /root/host-keys and install it to /mnt same as the existing pre-seeded-key path. Falls through to the original warning+confirm if the prompt is skipped, the path doesn't have the key, or the run isn't interactive at all. docs/auto-installer.md updated to mention the new fallback. Quick bash -n + shellcheck pass only, per request.
beatzaplenty added 1 commit 2026-07-22 02:57:31 +00:00
Prompt for a host-key path interactively as a third fallback
Check NixOS configurations / eval-hosts (pull_request) Successful in 10m19s
79e8f9f2ce
If neither /etc/host-keys nor /root/host-keys has the target's SSH
host key, auto-install.sh previously went straight to "continue
without one anyway?". Added a third option in between, gated on
[[ -t 0 ]] (only offered when there's an actual operator at stdin, never
in an unattended/non-interactive run): prompt for an arbitrary
directory (USB stick, other mount, etc.), and if the key pair is
there, copy it into /root/host-keys and install it to /mnt same as the
existing pre-seeded-key path. Falls through to the original
warning+confirm if the prompt is skipped, the path doesn't have the
key, or the run isn't interactive at all.

docs/auto-installer.md updated to mention the new fallback. Quick
bash -n + shellcheck pass only, per request.
beatzaplenty merged commit c53c1940d6 into main 2026-07-22 02:57:37 +00:00
This repo is archived. You cannot comment on pull requests.
No Reviewers
No labels
1 Participants
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: beatzaplenty/nixos#39