gerrit http 身份验证
我正在尝试设置 gerrit HTTP 身份验证。 我正在阅读 gerrit http 身份验证 上的文档其中简要讨论了如何设置apache,但是我到底应该在哪里放置这段代码并配置apache tomcat?
除此之外,我研究并发现了用于 http 身份验证的“siteminder”;我应该用它来代替吗?
我的要求是,我在自定义系统中拥有自己的一组用户帐户,并且我需要每个用户帐户都能够与 gerrit 交互,因此我认为 http 将允许自定义创建/复制每个帐户。
I'm trying to setup gerrit HTTP authentication.
I am reading the documentation at gerrit http authentication which briefly talks about how to setup apache but where exactly do I put this piece of code and configure apache tomcat?
Otherwise, I researched and found out about "siteminder" for http authentication; am I supposed to be using that instead?
My requirements are that I have my own set of user accounts in my custom system and I need each of my user accounts to be able to interact with gerrit so I figured http would allow custom creation/duplicate of each.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我花了一段时间才弄清楚这一点。
Tomcat已安装并测试。
然后我复制了 gerrit war 文件并将其放入 tomcat/webapps 中。然后从 tomcat 管理器 http://[host]:8080/manager/ 我安装了它(通过单击开始按钮)
然后我必须安装 mysql J Connector。基本上从 Mysql 下载它并将 jar 文件复制到 tomcat/lib
接下来,我在 tomcat/webapps/gerrit/META-INF 中创建了一个名为 Context.xml 的文件,
因为我在守护进程中使用了 bouncy castle,所以我必须复制 .jar 文件从原始安装到 tomcat/webapps/gerrit/WEB-INF/lib
然后我设法启动 gerrit 以查看它是否正常工作。尝试访问 http://[host]:8080/gerrit 这应该会给你一个来自 gerrit 的关于错误的 Apache conf 的错误。
然后我像这样重新配置了我的 apache 虚拟主机。因此,我使用 http://gerrit/gerrit 访问 gerrit
,然后在将请求传递到 tomcat 服务器之前使用 http auth。
Took me a while to figure this out.
Tomcat was installed and tested.
Then I copied gerrit war file over and put it in tomcat/webapps. Then from the tomcat manager http://[host]:8080/manager/ I installed it (by clicking the start button)
Then I had to install mysql J Connector. Basically download it from Mysql and copy the jar file into tomcat/lib
Next I created a file in tomcat/webapps/gerrit/META-INF called Context.xml
Because I had used bouncy castle with the daemon I had to copy the .jar file from original install to tomcat/webapps/gerrit/WEB-INF/lib
Then I managed to start gerrit to see if it was working. Try accessing http://[host]:8080/gerrit This should give you an error from gerrit about bad Apache conf.
Than I reconfigured my apache virtual host like this. So I access gerrit with http://gerrit/gerrit
This then uses http auth before passing your request onto the tomcat server.
试试这个(不需要 tomcat)
初始化一个新项目
etc/gerrit.config
vhost 配置 apache
Try this (no tomcat is needed)
initialize a new project
etc/gerrit.config
vhost config for apache
我知道这是一个旧线程,但我提供了一个关于 serverfault 的教程,用于在 tomcat 下设置 Gerrit。如果您仍然感兴趣,请访问:
https:// /serverfault.com/questions/383573/how-do-i-install-gerrit-under-tomcat-with-ldap
I know this is an old thread, but I've provided a tutorial on serverfault for setting up Gerrit under tomcat. If you're still interested, here it is:
https://serverfault.com/questions/383573/how-do-i-install-gerrit-under-tomcat-with-ldap