Regenerates the openssh-server host key pair(s) for a server and restarts sshd.
This script only regenerates keys the first time it is run; it can be inserted into a ServerTemplate's boot sequence, or run multiple times, without harm.
After running this script, make sure to terminate all open SSH connections to the server; this will ensure that sshd finishes restarting.
NOTE: your ssh client may give a warning or error after changing your host key.
Revision 9 | Oct 05, 2012
RS_TOKEN removed because core site no longer provides this.
Sign-up for RightScale