admin doc: clarified the instructions a little more

...it seems some admins are, well, not quite ready to be admins :)

(also some minor typo fixes slipped in)
This commit is contained in:
Sitaram Chamarty 2009-08-29 10:51:48 +05:30
parent d27af37d21
commit 4c2c55f2d1
3 changed files with 17 additions and 11 deletions

View file

@ -53,13 +53,13 @@ Here's how we migrated my work repos:
cp ~/repositories/gitosis-admin.git/gitosis-export/keydir/* keydir cp ~/repositories/gitosis-admin.git/gitosis-export/keydir/* keydir
9. **Important: expand** any multi-key filess you may have. See the "faq, 9. **Important: expand** any multi-key files you may have. See the "faq,
tips, etc" document in the doc directory for an explanation of what tips, etc" document in the doc directory for an explanation of what
multi-keys are, how gitosis does them and how gitolite does it multi-keys are, how gitosis does them and how gitolite does it
differently. differently.
You can split the keys manually, or use the following code (just You can split the keys manually, or use the following code (just
copy-paste it into you xterm): copy-paste it into your xterm):
wc -l keydir/*.pub | grep -v total | grep -v -w 1 | while read a b wc -l keydir/*.pub | grep -v total | grep -v -w 1 | while read a b
do do
@ -69,7 +69,7 @@ Here's how we migrated my work repos:
echo "$l" > ${b%.pub}@$i.pub echo "$l" > ${b%.pub}@$i.pub
(( i++ )) (( i++ ))
done done
v $b $b.done mv $b $b.done
done done
This will split each multi-key file (say "sitaram.pub") into individual This will split each multi-key file (say "sitaram.pub") into individual

View file

@ -1,16 +1,22 @@
# administering and running gitolite # administering and running gitolite
Note: some of the paths in this document use variable names. Just refer to
`~/.gitolite.rc` for the correct values, assuming you followed the
instructions in the "INSTALL" document.
### administer ### administer
* ask each user who will get access to send you a public key. See other * ask each user who will get access to send you a public key. See other
sources (for example sources (for example
[here](http: /sitaramc.github.com/0-installing/2-access-gitolite.html#generating_a_public_key)) [here](http://sitaramc.github.com/0-installing/2-access-gitolite.html#generating_a_public_key))
for how to do this for how to do this
* for each "user" in `$GL_CONF`, copy their public key to a file called * rename each public key according to the user's name, with a `.pub`
"user.pub" in `$GL_KEYDIR`. For example, mine would be called extension, like `sitaram.pub` or `john-smith.pub`. You can also use
"sitaram.pub" periods and underscores
* edit the config file (`$GL_CONF`) to add the new users in whatever way you * copy all these `*.pub` files to `$GL_KEYDIR`
like * edit the config file (`$GL_CONF`) and give the new users permissions as
required. The users names should be exactly the same as their keyfile
names, but without the `.pub` extension
* backup your `~/.ssh/authorized_keys` file if you feel nervous :-) * backup your `~/.ssh/authorized_keys` file if you feel nervous :-)
* cd to `$GL_ADMINDIR` and run `src/gl-compile-conf` * cd to `$GL_ADMINDIR` and run `src/gl-compile-conf`

View file

@ -69,7 +69,7 @@ those keys.
#### who am I? #### who am I?
As a developer, I send a file called "id_rsa.pub" to the gitolite admin. He As a developer, I send a file called `id_rsa.pub` to the gitolite admin. He
would rename it to "sitaram.pub" and put it in the key directory. Then he'd would rename it to "sitaram.pub" and put it in the key directory. Then he'd
add "sitaram" to the config file for the repos which I have access to. add "sitaram" to the config file for the repos which I have access to.