Project

General

Profile

Actions

Defect #10535

open

Atom feeds for the Project Activity contain incorrect hostname

Added by Artem Sheremet almost 12 years ago. Updated about 3 years ago.

Status:
Reopened
Priority:
Normal
Assignee:
Category:
Feeds
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

The link in the Atom feed (at least for Project Activity) contains a hostname detected by Rails, but not the one specified in settings.
This makes link unusable if the requests to Rails are proxified.

Versions:

Redmine:

SVN: http://redmine.rubyforge.org/svn/branches/1.3-stable revision 9240

Env:

Ruby version              1.8.7 (x86_64-linux)
RubyGems version          1.3.7
Rack version              1.1.2
Rails version             2.3.14
Active Record version     2.3.14
Active Resource version   2.3.14
Action Mailer version     2.3.14
Active Support version    2.3.14
Application root          /opt/redmine
Environment               production
Database adapter          mysql
Database schema version   20110902000000


Files

fix-10535-without-test.patch (1.6 KB) fix-10535-without-test.patch Go MAEDA, 2020-05-19 10:11
test-10535.patch (6.28 KB) test-10535.patch Go MAEDA, 2020-05-19 14:11

Related issues

Related to Redmine - Defect #17309: RSS feed gives away localhost linkClosed

Actions
Actions #1

Updated by Go MAEDA almost 4 years ago

Confirmed the issue. I think the links in the Atom feed should respect Setting.protocol and Setting.host_name.

The attached is a workaround for the issue.

Actions #2

Updated by Go MAEDA almost 4 years ago

Updated tests.

Actions #3

Updated by Go MAEDA over 3 years ago

  • Target version changed from Candidate for next major release to 4.2.0

Setting the target version to 4.2.0.

Actions #4

Updated by Go MAEDA over 3 years ago

  • Status changed from Confirmed to Closed
  • Assignee set to Go MAEDA
  • Resolution set to Fixed

Committed the patch.

Actions #5

Updated by Go MAEDA over 3 years ago

  • Related to Defect #17309: RSS feed gives away localhost link added
Actions #6

Updated by Go MAEDA about 3 years ago

  • Status changed from Closed to Reopened

r19810 generates incorrect links if Redmine is deployed using sub-URI.

For example, if ENV['RAILS_RELATIVE_URL_ROOT'] is '/dir' and Setting.host_name is 'example.net/dir', a link to an issue will be http://example.net/dir/dir/issues/1 ('dir' appears twice).

Actions #7

Updated by Go MAEDA about 3 years ago

Go MAEDA wrote:

r19810 generates incorrect links if Redmine is deployed using sub-URI.

For example, if ENV['RAILS_RELATIVE_URL_ROOT'] is '/dir' and Setting.host_name is 'example.net/dir', a link to an issue will be http://example.net/dir/dir/issues/1 ('dir' appears twice).

And also app/views/journals/index.builder should have been changed to support Setting.host_name but r19810 didn't.

I will revert the change.

Actions #8

Updated by Go MAEDA about 3 years ago

  • Target version deleted (4.2.0)
Actions

Also available in: Atom PDF