우리는 Gerrit를 설치하여 서버에서 저장소를 관리합니다. 지금까지 모든 것이 잘 작동하고 ssh를 사용하여 복제 할 수 있습니다.http를 apache2 뒤에 사용하는 Gerrit 복제본
Gerrit는 버전 2.14.2 아파치 2.4.18입니다.
/media/data/gerrit/etc/gerrit.config
[gerrit]
basePath = git
serverId = ed5a7ef7-289e-4590-9292-cbdede1b0dc9
canonicalWebUrl = http://repository.something.com/gerrit
[database]
type = h2
database = /media/data/gerrit/db/ReviewDB
[index]
type = LUCENE
[auth]
type = HTTP
logoutUrl = http://[email protected]/gerrit
[receive]
enableSignedPush = false
[sendemail]
smtpServer = mail.something.com
from = Code Review <[email protected]>
[container]
javaHome = /usr/lib/jvm/java-8-openjdk-amd64/jre
user = administrator
[sshd]
listenAddress = *:29418
[httpd]
listenUrl = proxy-http://127.0.0.1:8081/gerrit
[cache]
directory = cache
[plugins]
allowRemoteAdmin = true
[download]
command = checkout
command = cherry_pick
command = pull
scheme = ssh
scheme = http
[commitmessage]
maxSubjectLength = 80
maxLineLength = 100
longLinesThreshold = 10
rejectTooLong = false
[plugin "emoticons"]
showEmoticons = true
[reviewers]
enableREST = true
enableUI = true
ignoreDrafts = true
autoAddReviewers = false
maxReviewers = 1
enableLoadBalancing = false
plusTwoRequired = true
plusTwoAge = 8
plusTwoLimit = 10
[gitweb]
type = custom
linkname = log
url = http://repository.something.com/cgit
project = /${project}.git
branch = /${project}.git/log
revision = /${project}.git/commit/?id=${commit}
filehistory = /${project}.git/log
[lfs]
plugin = lfs
/etc/apache2/mods-enable/gerrit.conf : (필요한 경우 검열) 우리의 구성 파일입니다
ProxyPassMatch /([[:alnum:]-]+)\.git(.*) http://localhost:8081/gerrit/a/$1.git$2
ProxyPass /gerrit http://localhost:8081/gerrit nocanon
ProxyPassReverse /gerrit http://localhost:8081/gerrit nocanon
ProxyRequests Off
<Proxy http://localhost:8081/gerrit>
Order deny,allow
Allow from all
</Proxy>
<Location /gerrit>
AuthType Digest
AuthName "gerrit"
AuthUserFile /etc/apache2/.htdigest
Require valid-user
</Location>
내가 말했듯이 ssh를 사용한 복제는 잘 작동합니다. 하지만 http를 사용하여 복제하려고하면 인증 오류가 발생합니다. 다른 설정을 사용하여 mods가 활성화 된 사이트와 사용 가능한 사이트에서 별도의 설정 파일을 사용하여 많은 시도를했습니다.
어떤 생각이 잘못되었을 수 있습니까?
이미 보았 듯이 repository.someting.com에 방문 페이지가 있으며 repository.something.com/gerrit를 사용하여 Gerrit에 액세스합니다.
이 모든 아파치 구성 물건은 나에게 완전히 새로운 -.- 그래서 내가 자세한 내용은 디버깅하는 아파치 로그 레벨을 변경 ^^