【问题标题】:Run Gerrit on Port other than 8080在 8080 以外的端口上运行 Gerrit
【发布时间】:2017-03-10 18:42:52
【问题描述】:

现在,我的gerrit.config 看起来像:

[gerrit]
    basePath = git
    serverId = 72317765-a256-4938-a998-5d6xxxxxxed1
    canonicalWebUrl = http://localhost:8080/
[database]
    type = h2
    database = /root/gerrit_setup/db/ReviewDB
[auth]
    type = OPENID
[receive]
    enableSignedPush = false
[sendemail]
    smtpServer = localhost
[container]
    user = root
    javaHome = /usr/lib/jvm/java-7-openjdk-i386/jre
[sshd]
    listenAddress = *:29418
[httpd]
    listenUrl = http://*:8080/
[cache]
    directory = cache

我在 AWS Ubuntu 服务器上运行它,我需要更改 PORT gerrit 运行。我已经在同一个端口(8080)上设置了 Jenkins。

我尝试将 gerrit.canonicalWebUrl 更改为 8085,但我怀疑它是否与 httpd.port 配置有关。

将端口更改为 8085 后,我运行了./gerrit.sh start,结果为Starting Gerrit Code Review: OK,但http://x.x.x.x:8085/ 仍然没有响应。

我对在服务器上配置代码审查工具(或任何其他工具)完全陌生,所以请逐步描述解决方案。

【问题讨论】:

    标签: ubuntu gerrit


    【解决方案1】:

    您需要更改以下内容:

    [httpd]
        listenUrl = http://localhost:8085/
    

    【讨论】:

    • 试过,重新启动 gerrit 并显示 Starting Gerrit Code Review: OKhttp://x.x.x.x:8085/ 不会响应。我也试过9999端口,以防8085也被占用。
    • 嗯...我仔细检查了一遍,我认为没有任何其他配置可以更改。您可以使用“nmap HOST”检查端口
    【解决方案2】:

    如果我是你。 我安装了 gerrit 用户重新索引。

    安装 gerrit 时。你输入端口号。

    当你安装了 gerrit。 “gerrit.config”文件将被更改。

    [格里特]

    basePath = git

    serverId = 72317765-a256-4938-a998-5d6xxxxxxed1

    canonicalWebUrl = http://localhost:8085/

    [httpd]

    listenUrl = http://localhost:8085/

    试试~!

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-02-12
      • 1970-01-01
      • 2023-03-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-05-27
      • 1970-01-01
      相关资源
      最近更新 更多