Sharing ssh keys

Here you can discuss every aspect of Debian. Note: not for support requests!

Sharing ssh keys

Postby Munty Scruntfundle » 2019-03-19 14:30

Next question for the day...

If have 128 debian/raspbian nodes on a closed network. This is going to be a collaborative cluster, usually you would have a header node and a load of slaves, but I'm trying to do something different.

I want every node to have access to every node. I'm sharing data in all sorts of ways and some of it requires ssh instructions.

So. Is there any easy way to create keys and share them all within the cluster? If not it's going to take days!!

Many thanks.
Munty Scruntfundle
 
Posts: 54
Joined: 2018-11-27 16:53

Re: Sharing ssh keys

Postby arzgi » 2019-03-19 16:13

There is ssh-copy-id, which helps shearing keys. I've only used it to one host at time, but you could write a script, which would in loop read one host from file, and call ssh-copy-id whit it.

Fortunately ssh-copy-id -n is try run option. I leave it to you to test, will it halt the script when it tries to copy keys to itself. That would make it bit more challenging, but not too demanding.
arzgi
 
Posts: 673
Joined: 2008-02-21 17:03
Location: Finland


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 8 guests

fashionable