runnig gerrit under nginx

1,135 views
Skip to first unread message

bessarabov

unread,
Sep 9, 2010, 10:45:39 AM9/9/10
to Repo and Gerrit Discussion
I'm trying to set up gerrit with http auth. It works fine under
apache2 or standalone, but I want to run in under nginx. In gerrint
file logs/error_log I have such an error:

[2010-09-09 18:37:08,019] WARN org.eclipse.jetty.util.log :
HttpException(400,null,null)


My nginx config is something like:


server {
listen 80;
server_name example.com;

access_log /var/log/nginx/gerrit.log;

location / {
proxy_pass https://192.168.1.100:8080/;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For
$proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_read_timeout 300;
auth_basic "closed site";
auth_basic_user_file /etc/nginx/gerrit.htpasswd;
}
}

Any ideas of what is wrong here?

Shawn Pearce

unread,
Sep 16, 2010, 10:50:11 AM9/16/10
to bessarabov, Repo and Gerrit Discussion
On Thu, Sep 9, 2010 at 07:45, bessarabov <ivanbes...@gmail.com> wrote:
> I'm trying to set up gerrit with http auth. It works fine under
> apache2 or standalone, but I want to run in under nginx. In gerrint
> file logs/error_log I have such an error:
>
> [2010-09-09 18:37:08,019] WARN  org.eclipse.jetty.util.log :
> HttpException(400,null,null)

That's all we're getting from Jetty? Ouch. That doesn't tell me anything. :-(

> My nginx config is something like:

...


> Any ideas of what is wrong here?

I'd have to install nginx and try to debug Jetty to get more detail
since the log message is so sparse.

Reply all
Reply to author
Forward
0 new messages