| Issue 760: | Code_Review email notification contains internal server name and links | |
| 2 people starred this issue and may be notified of changes. | Back to list |
Affected Version: All What steps will reproduce the problem? 1. Setup gerrit2 behind a proxy https server and an internal sshd daemon 2. Clients connect using ssh tunneling setup: .ssh/config Host internal_gerrit User eihenacho ProxyCommand ssh user@proxy nc -w 23 internal 29418 ServerAliveInterval 4 3. Create a review and include --reviewer and --cc $ git push --receive-pack='git receive-pack --reviewer=user1@company.com --cc=eihenacho@company.com' internal_gerrit:bionic HEAD:refs/for/code_review What is the expected output? Email received: Hello user@company.com, I'd like you to do a code review. Change I94b05e66 for code_review in bionic: Added a file --- M test.txt git pull ssh://internal_gerrit:29418/bionic refs/changes/06/6/1 -- Gerrit-MessageType: newchange Gerrit-Project: bionic Gerrit-Branch: code_review What do you see instead? Hello user@company.com, I'd like you to do a code review. Change I94b05e66 for code_review in bionic: Added a file --- M test.txt git pull ssh://internalservername.company.com:29418/bionic refs/changes/06/6/1 -- Gerrit-MessageType: newchange Gerrit-Project: bionic Gerrit-Branch: code_review Please provide any additional information below. Question: How does the HOSTNAME for the git command get generated? Is there way to format that value?
Oct 26, 2010
#1
eihena...@googlemail.com
Nov 3, 2010
Try changing the gerrit.canonicalGitUrl entry in etc/gerrit.config.
Dec 9, 2010
That works for issue 628 . This is a different issue. Seems those values are not taken from the aforementioned variable.
Sep 27, 2011
I'm having the same problem. The email that goes out uses a shorten internal hostname. I'd like to change or specify the URL where gerrit is hosted.
Sep 27, 2011
Set gerrit.canonicalWebUrl
Status:
Invalid
Oct 11, 2011
I tried that. problem is that we have http (backend) and a https (frontend apache proxy).. so it is a bit more complicated.. Setting the value does not work.
We have the following in the gerrit cfg file:
httpd]
listenUrl = proxy-http://backendip:8080/gerrit/
The frontend apache proxy is setup with the correct rules as per the gerrit documentation. This all works and users can access the no problems.
The only issue is that the emails are shown with http instead of https! Any ideas?
Is there a way to edit the mail templates to force this?
eg:
Charl Spent has posted comments on this change.
Change subject: This is a test
......................................................................
--
To view, visit http://domain-name/gerrit/2
To unsubscribe, visit http://domain-name/gerrit/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I1e4bae56b87308230108ac6bd26eb7bef2460b3b
Gerrit-PatchSet: 1
Gerrit-Project: new/test
Gerrit-Branch: review
Gerrit-Owner: Clarke Kent <clarke.kent@ckent.co.uk>
Gerrit-Reviewer: Charl Spent <charl.spent@ckent.co.uk>
Gerrit-Reviewer: Clarke Kent <clarke.kent@ckent.co.uk>
Oct 11, 2011
After writing the above. I realised that I was being a dummy.. The solution was to use
[httpd]
listenUrl = proxy-https://backendip:8080/gerrit/
Certainly helps when one takes time to read the documentation properly.. :-)
|
|
| ► Sign in to add a comment |