(password access) specify comment field in generated ssh pub key

since gl-shell-setup runs as root, the comment in the generated key was
'root@...' instead of whatever userid it was being created for.

This does not affect gitolite or ssh but it seems some people don't
treat "comment" and "comment" and actually *do* stuff with it.

(only code is from author; commit message is from committer)
This commit is contained in:
Tomas Paladin Volf 2011-11-27 00:13:36 +01:00 committed by Sitaram Chamarty
parent af6820a94b
commit b6ba3cc975

View file

@ -59,7 +59,7 @@ then
}
[ -f .ssh/id_rsa.pub ] || {
ssh-keygen -q -N "" -f .ssh/id_rsa >&2
ssh-keygen -q -N "" -C $user@`hostname` -f .ssh/id_rsa >&2
chown $user .ssh/id_rsa .ssh/id_rsa.pub
chmod go-rw .ssh/id_rsa
chmod go-w .ssh/id_rsa.pub