-
Notifications
You must be signed in to change notification settings - Fork 16
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
Setting KnownHosts for SSH #2
Comments
SSH also supports having a shared CA that can generate keys for all of your workers. Then you can configure the CA public key in your master an access all the workers automatically. It does add a step to generate the ssh keys and transmit them to the workers. I don't know how you start your new workers but if you use EC2 you could generate the key on your machine and then pass it to the cloud-init. |
@peti I think we should note this in the tutorial. I'd go with |
It's possible to avoid setting Here is an example courtesy of @cleverca22 https://gist.github.com/cleverca22/e2f674c4f8dc0057879e25b1c6a3ef50 |
Hydra queue runner doesn't automatically accept new hosts (due to default behavior in OpenSSH which is to ask for accepting the new host).
There are two ways to do that automatically:
sshPublicHostKey
which should be base64 encoded fingerprint line (not documented, but see commit NixOS/hydra@2a7fbd5), I will push a commit to enable setting this in NixOSprograms.ssh.extraConfig = "StrictHostKeyChecking no";
inhydra-master
I chose the latter because it's a very low security tradeoff. SSH will still bail out if there is host mismatch, but it will automatically accept new hosts.
If hosts/key is hacked on first connection I think you're in trouble anyway.
The text was updated successfully, but these errors were encountered: