diff options
author | Silvino Silva <silvino@bk.ru> | 2018-04-13 21:27:44 +0100 |
---|---|---|
committer | Silvino Silva <silvino@bk.ru> | 2018-04-13 21:27:44 +0100 |
commit | d1e992fd5302e0514206b46c864cb15d44bd22f2 (patch) | |
tree | 8c97a7b9433df067d56397a0b88892968e7e788e | |
parent | eafb8ac15aef8e13144c75f1d35b157ff0a9640f (diff) | |
download | doc-d1e992fd5302e0514206b46c864cb15d44bd22f2.tar.gz |
gitolite revision
-rw-r--r-- | tools/gitolite.html | 52 | ||||
-rw-r--r-- | tools/index.html | 1 |
2 files changed, 28 insertions, 25 deletions
diff --git a/tools/gitolite.html b/tools/gitolite.html index e7b7067..52d8cbd 100644 --- a/tools/gitolite.html +++ b/tools/gitolite.html @@ -23,7 +23,16 @@ <pre> # useradd -r -s /bin/bash -U -m -d /srv/gitolite gitolite + </pre> + + <p>Permissions for /srv/gitolite/repositories directories should be + 0750/drwxr-x---.</p> + + <pre> # chown gitolite:gitolite /srv/gitolite + $ chmod -R o-rx /srv/gitolite/repositories + $ chmod -R g+rx /srv/gitolite/repositories + $ chmod -R o+r /srv/gitolite/projects.list </pre> <p>Password is necessary so the user is not @@ -33,7 +42,6 @@ <pre> # passwd gitolite </pre> - <p>Copy public key that will be used for authenticating gitolite administrator, read <a href="openssh.html#ssh">ssh</a> how to @@ -734,26 +742,19 @@ our $projects_list_group_categories = 1; </pre> - <h3>5.2. Configure nginx</h3> + <h3>5.2. Configure fcgiwrap</h3> - <p>Edit /etc/rc.d/fcgiwrap to run as www user member of www group;</p> + <p>Edit /etc/rc.d/fcgiwrap to run as www user member of gitolite group;</p> <pre> USER=www - GROUP=www + GROUP=gitolite </pre> - <p>Permissions for /srv/gitolite/repositories directories should be - 0750/drwxr-x---.</p> - - <pre> - $ chown gitolite:www /srv/gitolite - $ chown -R gitolite:www /srv/gitolite/projects.list - $ chown -R gitolite:www /srv/gitolite/repositories - </pre> + <h3>5.3. Configure nginx</h3> <p>A link from gitweb don't work under grsecurity since user www can't - follow simlink to root. Make a copy, later deploy via gitolite hook.</p> + follow simlink to root. Making a copy allows to later deploy via gitolite hook.</p> <p>Link;</p> <pre> @@ -761,6 +762,7 @@ </pre> <p>Copy;</p> + <pre> # cp -r /usr/share/gitweb /srv/www </pre> @@ -769,7 +771,7 @@ <a href="nginx.html#virtual-host">nginx virtual host</a>;</p> <pre> - location /gitweb/gitweb.cgi { + location /git/gitweb.cgi { alias /srv/www/gitweb; include fastcgi_params; gzip off; @@ -778,13 +780,13 @@ fastcgi_pass unix:/var/run/fcgiwrap.sock; } - location /gitweb { + location /git { alias /srv/www/gitweb; index gitweb.cgi; } </pre> - <h3>5.3. Configure gitolite</h3> + <h3>5.4. Configure gitolite</h3> <p>Edit <a href="conf/srv/gitolite/.gitolite.rc">/srv/gitolite/.gitolite.rc</a>, @@ -799,14 +801,6 @@ GIT_CONFIG_KEYS => '.*', </pre> - <p>Fix permissions;</p> - - <pre> - $ sudo chown -R gitolite:gitolite /srv/gitolite - $ sudo chmod g+rx /srv/gitolite/projects.list - $ sudo chmod -R 755 /srv/gitolite/repositories/ - </pre> - <p>Edit gitolite-admin/conf/gitolite.conf;</p> <pre> @@ -821,12 +815,20 @@ config gitweb.category = Projects </pre> + <h2 id="git-daemon">6. Git-daemon</h2> + + <p>Configure to run as user;</p> + + <pre> + USER=www + GROUP=gitolite + </pre> + <a href="index.html">Tools Index</a> <p>This is part of the c9-doc Manual. Copyright (C) 2018 c9 team. See the file <a href="../fdl-1.3-standalone.html">Gnu Free Documentation License</a> for copying conditions.</p> - </body> </html> diff --git a/tools/index.html b/tools/index.html index 2b6a4d4..5ecc70b 100644 --- a/tools/index.html +++ b/tools/index.html @@ -149,6 +149,7 @@ <li><a href="gitolite.html#admin">3. Gitolite Administration</a></li> <li><a href="gitolite.html#hooks">4. Gitolite Hooks</a></li> <li><a href="gitolite.html#gitweb">5. Gitweb</a></li> + <li><a href="gitolite.html#git-daemon">6. Git-daemon</a></li> </ul> </li> <li><a href="postgresql.html">Postgresql</a> |