Loading

gitweb配置

基于ssh的git服务器搭建可浏览:https://www.cnblogs.com/wswind/p/10373881.html

安装gitweb和apache

yum -y install gitweb
yum -y install httpd

配置gitweb库地址 /etc/gitweb.conf

$projectroot = '/opt/git'

配置权限

chmod 770 -R /opt/git
usermod -a -G git apache

配置 /etc/httpd/conf.d/git.conf 注意Options中间没有+

<VirtualHost *:80>
	ServerName gitserver
	DocumentRoot /var/www/gitweb
	<Directory /var/www/gitweb>
		Options ExecCGI FollowSymLinks SymLinksIfOwnerMatch
		AllowOverride All
		order allow,deny
		Allow from all
		AddHandler cgi-script cgi
		DirectoryIndex gitweb.cgi
	</Directory>
</VirtualHost>

如需设置apache登录密码,请访问:

http://www.cnblogs.com/loveCloud/archive/2012/01/12/2320636.html

参考:

《Pro Git》- GitWeb

https://www.cnblogs.com/gtarcoder/p/5309229.html

posted @ 2019-02-15 10:43  wswind  阅读(443)  评论(0编辑  收藏  举报