| <html> | |
| <head> | |
| <title>Configuration Error - Gerrit Code Review</title> | |
| <style> | |
| .check_msg { | |
| background: orange; | |
| padding: 20px; | |
| width: 25em; | |
| } | |
| .apache_config { | |
| font-size: small; | |
| border: 1px dotted black; | |
| width: 40em; | |
| margin-left: 5em; | |
| padding: 1em; | |
| } | |
| .apache_auth { | |
| background: lightgrey; | |
| } | |
| #loginHeader { | |
| font-weight: bold; | |
| background: lightgrey; | |
| padding-left: 5px; | |
| padding-right: 5px; | |
| } | |
| </style> | |
| </head> | |
| <body> | |
| <h1>Configuration Error</h1> | |
| <div class='check_msg'> | |
| <b>Check the HTTP server's authentication settings.</b> | |
| </div> | |
| <p> | |
| The HTTP server did not provide the username in the | |
| <span id='loginHeader'>HEADER</span> header when it | |
| forwarded the request to Gerrit Code Review. | |
| </p> | |
| <p> | |
| If the HTTP server is Apache HTTPd, check the proxy | |
| configuration includes an authorization directive with | |
| the proper location, ensuring it ends with '/': | |
| </p> | |
| <pre class='apache_config'> | |
| <VirtualHost <span class='ServerName'>review.example.com</span><span class='ServerPort'>:80</span>> | |
| ServerName <span class='ServerName'>review.example.com</span> | |
| ProxyRequests Off | |
| ProxyVia Off | |
| ProxyPreserveHost On | |
| <Proxy *> | |
| Order deny,allow | |
| Allow from all | |
| </Proxy> | |
| <div class='apache_auth'> <Location <span class='ContextPath'>/r</span>/login/> | |
| AuthType Basic | |
| AuthName "Gerrit Code Review" | |
| Require valid-user | |
| ... | |
| </Location></div> | |
| AllowEncodedSlashes On | |
| ProxyPass <span class='ContextPath'>/r</span>/ http://...<span class='ContextPath'>/r</span>/ nodecode | |
| </VirtualHost> | |
| </pre> | |
| </body> | |
| </html> |