List for cgit developers and users
 help / color / mirror / Atom feed
From: john at keeping.me.uk (John Keeping)
Subject: Can I get detailed Cgit logs?
Date: Tue, 25 Feb 2014 19:25:03 +0000	[thread overview]
Message-ID: <20140225192503.GB18371@serenity.lan> (raw)
In-Reply-To: <530CE3A8.3000500@thewordnerd.info>

On Tue, Feb 25, 2014 at 12:40:40PM -0600, Nolan Darilek wrote:
> On 02/25/2014 12:08 PM, John Keeping wrote:
> > How is CGit able to see the repositories? Unlike Jenkins, CGit does 
> > not speak any of the Git protocols, it expects to see repositories in 
> > the file system. Are you Docker containers sharing an underlying 
> > filesystem, or do you have some external job that is cloning the 
> > repositories for CGit? 
> 
> Sharing an underlying filesystem, yes. Git repositories are in a
> volume shared by Gitolite and Cgit.
> 
> >> Is there any way to get detailed error logs? I don't see any in my
> >> Apache logs, which could mean a misconfiguration on that end. But having
> >> access to some sort of detailed error log would be very helpful in
> >> debugging this.
> > 
> > Since CGit is a CGI program, you can just run it and see what happens.
> > You may want to export PATH_INFO=/ before doing so to make sure it
> > generates the index.
> 
> OK, new complicating factor. If I spin up a container that I can 
> interact with (I.e. running a shell) then running cgit.cgi directly 
> shows my repositories. If I spin up a non-interactive container (I.e. 
> running in the background) then I see no repositories. The only 
> difference between these environments should be the lack of an attached 
> stdin/stdout.

Is there any chance that the CGIT_CONFIG environment variable is defined
differently for the two invocations?  If it is not defined then CGit
will default to a built-in location (by default /etc/cgitrc).

> So is there any way to redirect CGI errors to the Apache error log? I 
> have the following in my configuration:
> 
>    LogLevel info
>    CustomLog |cat combined
> 
> My assumption is that this will redirect all relevant logs to stdout so 
> they are visible in the "docker logs" command. But I only see server 
> accesses, no CGI errors.

I have never tried using a CustomLog like that, but with a default
logging setup I do see CGit errors in /var/log/apache2/error_log.


      parent reply	other threads:[~2014-02-25 19:25 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-25 17:53 nolan
2014-02-25 18:08 ` john
2014-02-25 18:40   ` nolan
2014-02-25 19:24     ` nolan
2014-02-25 19:29       ` john
2014-02-25 19:25     ` john [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140225192503.GB18371@serenity.lan \
    --to=cgit@lists.zx2c4.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).