davido / gerrit-oauth-provider

OAuth2 authentication provider for Gerrit Code Review. Please upload changes for review to: https://gerrit-review.googlesource.com/#/admin/projects/plugins/oauth
Apache License 2.0
140 stars 84 forks source link

Why Gerrit jump to https schema while I config the cas root-url of http schema? #150

Closed hundanLi closed 3 years ago

hundanLi commented 3 years ago

When I test the cas oauth sign in, it jump to https schema, however, my config specify http. The following is my etc/gerrit.config:

[gerrit]
        basePath = git
        canonicalWebUrl = http://10.120.199.200:8080/
        serverId = 5a470d58-91ba-464d-92a6-791c2faed744
[database]
        type = h2
        database = db/ReviewDB
[container]
        javaOptions = "-Dflogger.backend_factory=com.google.common.flogger.backend.log4j.Log4jBackendFactory#getInstance"
        javaOptions = "-Dflogger.logging_context=com.google.gerrit.server.logging.LoggingContext#getInstance"
        user = qiansheng_huang
        javaHome = /opt/jdk/jdk1.8.0_121/jre
        heapLimit = 512m
[index]
        type = lucene
[auth]
        type = OAUTH
        gitBasicAuthPolicy = HTTP
[receive]
        enableSignedPush = true
[sendemail]
        smtpServer = localhost
[sshd]
        listenAddress = *:29418
[httpd]
        listenUrl = http://*:8080/
[cache]
        directory = cache
[plugin "gerrit-oauth-provider-cas-oauth"]
        client-id = gerrit
        client-secret = 123456
        root-url = http://10.124.105.28:9080/cas
        fix-legacy-user-id = false

Any help, Please?