cannot get cgit display anything except the repo listing page

Torsten Kuehnel net_seeker at web.de
Fri Aug 13 21:22:06 UTC 2021


On Fri, 13 Aug 2021 09:12:05 +0200
Torsten Kuehnel <net_seeker at web.de> wrote:

Switching to uwsgi to connect nginx with cgit works out. Looks like fcgiwrap messes things up. Don't ask me for the exact reason.

> Dear cgit developer,
>
> i have a problem getting cgit display useful information.
> i compiled and installed cgit-1.2.3 like it is decribed in the README file and set it up via nginx fastcgi fcgiwrap
>
> nginx config:
>
> server {
> 	listen 85.17.xx.xx:443 ssl;
> 	server_name my.domain.com;
>         root /var/www/htdocs/cgit;
>
>         access_log  /var/log/cgit/access.log;
>         error_log   /var/log/cgit/error.log;
>
>         ssl_certificate /etc/letsencrypt/live/my.domain.com/fullchain.pem;
>         ssl_certificate_key /etc/letsencrypt/live/my.domain.com/privkey.pem;
>         include /etc/letsencrypt/options-ssl-nginx.conf;
>         ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
> 	try_files   $uri @cgit;
>
>         location ~* ^.+\.(css|png|ico)$ {
>                  expires 0;
>             }
>
>         location @cgit {
>                 include fastcgi_params;
>                 fastcgi_param  SCRIPT_FILENAME  /var/www/htdocs/cgit/cgit.cgi;
>                 fastcgi_pass   unix:/var/run/fcgiwrap.socket;
>                 fastcgi_param  PATH_INFO $uri;
>                 fastcgi_param  HTTP_HOST $server_name;
>                 fastcgi_param  QUERY_STRING  $args;
>         }
> }
>
>
> /etc/cgitrc:
>
> root-title=Git Verzeichnisse
> css=/cgit.css
> logo=/cgit.png
> snapshots=tar.gz tar.bz2
>
> scan-path=/tmp/
>
> virtual-root=/
> enable-index-links=1
> enable-log-filecount=1
> enable-log-linecount=1
> enable-commit-graph=1
>
> In the /tmp/ directory is a git repository "repo01" with one commit in it, owned completely by www-data, the user nginx is run with.
>
> The result ist displaying the proper cgit "welcome" page with the one repo listed, Idle for 8 minutes. But the problem is, following any of the presented links like "summary", "log", or "tree", results in displaying the same entry page which lists the repo, but shows no content.
>
> Spent to days on playing around with the nginx and cgitrc config, but nothing useful happens. The permissions on the repo are fully set to the www-data user. The url changes when i choose a link, but the displayed result is always the same, displaying the overview page of available repos.
>
> Thanks for any help in advance.
>
> Torsten Dieter Kuehnel
> --
> Torsten Kuehnel <net_seeker at web.de>


--
Torsten Kuehnel <net_seeker at web.de>


More information about the CGit mailing list