Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Set BatchMode for ssh-copy-id #258

Closed
wants to merge 1 commit into from
Closed

fix: Set BatchMode for ssh-copy-id #258

wants to merge 1 commit into from

Conversation

dantefromhell
Copy link
Contributor

ssh-copy-id can hang indefinitely at the SSH password prompt if Server is configured to allow KeyboardAuthentication and PubKeyAuth fails.

SSH BatchMode instructs the ssh client to disable all interactive user prompts like password and host key confirmation.

Using the terraform module without BatchMode can result in a terraform apply run hanging "forever" at the password prompt. With BatchMode enabled the terraform apply run fails correctly.

`ssh-copy-id` can hang indefinitely at the SSH password prompt if Server is configured to allow KeyboardAuthentication and PubKeyAuth fails.

SSH BatchMode instructs the ssh client to disable all interactive user prompts like password and host key confirmation.

Using the terraform module without `BatchMode` can result in a terraform apply run hanging "forever" at the password prompt. 
With BatchMode enabled the terraform apply run fails correctly.
@dantefromhell
Copy link
Contributor Author

Digging through the code a bit more I suspect this could happen during all steps of nixos-anywhere that use SSH.

I guess the question is if running nixos-anywhere from the CLI should support the use-case of entering the password and this issue would be better fixed by the terraform module setting BatchMode=yes via the --ssh-option parameter?

Please advice.

@dantefromhell dantefromhell closed this by deleting the head repository Dec 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant