Skip to content

Commit e30c874

Browse files
committed
Let NixOps provide known_hosts independently of user known_hosts
Companion of NixOS/nixops#1464
1 parent 0056e04 commit e30c874

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

nixops_aws/backends/ec2.py

+12
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,18 @@ def _ip_for_ssh_key(self):
488488
else:
489489
return self.public_ipv4
490490

491+
def get_ssh_host_keys(self):
492+
return (
493+
self.private_ipv4
494+
+ " "
495+
+ self.public_host_key
496+
+ "\n"
497+
+ self.public_ipv4
498+
+ " "
499+
+ self.public_host_key
500+
+ "\n"
501+
)
502+
491503
def _booted_from_ebs(self):
492504
return self.root_device_type == "ebs"
493505

0 commit comments

Comments
 (0)