Cgit setup
Cgit setup
Hi guys! Recently switched to VestaCP from virtualmin; loving so far...
I need to setup a cgit server under a Vesta managed domain, git.mydonain.net, but I didn't have yet grasp how to do it.
Cgit configure itself as an Apache extension, under /etc/apache2/conf. I think that I should copy it's setup in my /home/$user/$mydomain/conf/web apache2 conf, but even if apache2 and nginx restart successfully, accessing http(s)://$mydonain/cgit give a 500 error...
Any clue?
I need to setup a cgit server under a Vesta managed domain, git.mydonain.net, but I didn't have yet grasp how to do it.
Cgit configure itself as an Apache extension, under /etc/apache2/conf. I think that I should copy it's setup in my /home/$user/$mydomain/conf/web apache2 conf, but even if apache2 and nginx restart successfully, accessing http(s)://$mydonain/cgit give a 500 error...
Any clue?
Re: Cgit setup
So, managed with a new template. Here it is:
This reflect the default cgit setup in Debian 9.
Code: Select all
<VirtualHost %ip%:%web_port%>
ServerName %domain_idn%
%alias_string%
ServerAdmin %email%
DocumentRoot %docroot%
ScriptAlias /cgi-bin/ %home%/%user%/web/%domain%/cgi-bin/
ScriptAlias /cgit/ "/usr/lib/cgit/cgit.cgi/"
RedirectMatch ^/cgit$ /cgit/
Alias /cgit-css "/usr/share/cgit/"
<Directory "/usr/lib/cgit/">
AllowOverride None
Options ExecCGI FollowSymlinks
Require all granted
</Directory>
Alias /vstats/ %home%/%user%/web/%domain%/stats/
Alias /error/ %home%/%user%/web/%domain%/document_errors/
#SuexecUserGroup %user% %group%
CustomLog /var/log/%web_system%/domains/%domain%.bytes bytes
CustomLog /var/log/%web_system%/domains/%domain%.log combined
ErrorLog /var/log/%web_system%/domains/%domain%.error.log
<Directory %docroot%>
AllowOverride All
Options +Includes -Indexes +ExecCGI
php_admin_value open_basedir %docroot%:%home%/%user%/tmp
php_admin_value upload_tmp_dir %home%/%user%/tmp
php_admin_value session.save_path %home%/%user%/tmp
php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -f info@%domain_idn%"
</Directory>
<Directory %home%/%user%/web/%domain%/stats>
AllowOverride All
</Directory>
<IfModule mod_ruid2.c>
RMode config
RUidGid %user% %group%
RGroups www-data
</IfModule>
<IfModule itk.c>
AssignUserID %user% %group%
</IfModule>
IncludeOptional %home%/%user%/conf/web/%web_system%.%domain%.conf*
</VirtualHost>
-
- Support team
- Posts: 1111
- Joined: Tue Jul 30, 2013 10:18 pm
- Contact:
- Os: CentOS 6x
- Web: nginx + php-fpm
Re: Cgit setup
If you use nginx no sense to use apache for cgit.
Try nginx config from here: https://gist.github.com/stran12/1394757
Try nginx config from here: https://gist.github.com/stran12/1394757