Project

General

Profile

Actions

Defect #2811

closed

Redmine SVN (Trunk) r2519 doesn't work in subdirectory

Added by Egor Morozov over 15 years ago. Updated over 15 years ago.

Status:
Closed
Priority:
Urgent
Assignee:
-
Category:
-
Target version:
-
Start date:
2009-02-23
Due date:
% Done:

0%

Estimated time:
Resolution:
Affected version:

Description

Hello!

I've updated Redmine to the latest SVN revision today and it stopped working. After resolving several issues with plugins I have this error message appearing:

ActionController::RoutingError (No route matches "/redmine/" with {:method=>:get}):
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/routing/recognition_optimisation.rb:66:in `recognize_path'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/routing/route_set.rb:386:in `recognize'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:182:in `handle_request'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch_unlocked'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:123:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:122:in `synchronize'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:122:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch_cgi'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:39:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/request_handler.rb:38:in `process_request'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_request_handler.rb:165:in `main_loop'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:321:in `start_request_handler'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:146:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:163:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:132:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:163:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:131:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:234:in `spawn_rails_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:217:in `synchronize'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:217:in `spawn_rails_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:126:in `spawn_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:251:in `handle_spawn_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_server.rb:317:in `__send__'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_server.rb:317:in `main_loop'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_server.rb:168:in `start_synchronously'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/bin/passenger-spawn-server:46

I have Redmine installed on FreeBSD, available at https://adm.lan/redmine/ (running Apache 2.2)

I've tried both Passenger & FastCGI, none is working.

Actions #1

Updated by Egor Morozov over 15 years ago

Oh, by the way, I was upgrading from r2483.

Actions #2

Updated by Jean-Baptiste Barth over 15 years ago

There were many changes in r2493, maybe your problem is related to that, you should look at this news

Actions #3

Updated by Egor Morozov over 15 years ago

Hello!

I've read this, installed Rails 2.2.2 and executed
rake config/initializers/session_store.rb

I've also removed all my custom plugins to check if it's okay, but it's still not working.

I've tried changing config/routes.rb:

map.home '', :controller => 'welcome'
to
map.home '/redmine', :controller => 'welcome'

And welcome page opened although the styles and internal pages didn't work.

Changing
map.signin 'login', :controller => 'account', :action => 'login'
to
map.signin 'redmine/login', :controller => 'account', :action => 'login'

Allowed me to open login page, but it's really strange.

Hope this information will help.

Thanks.

Actions #4

Updated by Jean-Baptiste Barth over 15 years ago

Seems like your problem is related to the fact you're running redmine under a subdirectory. Maybe this post will help you (especially the solution proposed by Jean-Philippe)

Actions #5

Updated by Egor Morozov over 15 years ago

I've added the line. It works, but the real paths are not working:

ActionController::RoutingError (No route matches "/stylesheets/jstoolbar.css" with {:method=>:get}):
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/routing/recognition_optimisation.rb:66:in `recognize_path'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/routing/route_set.rb:386:in `recognize'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:182:in `handle_request'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch_unlocked'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:123:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:122:in `synchronize'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:122:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch_cgi'
    /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:39:in `dispatch'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/request_handler.rb:38:in `process_request'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_request_handler.rb:165:in `main_loop'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:321:in `start_request_handler'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:146:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:163:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:132:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:163:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/utils.rb:161:in `safe_fork'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/railz/application_spawner.rb:131:in `spawn_application!'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:234:in `spawn_rails_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:217:in `synchronize'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:217:in `spawn_rails_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:126:in `spawn_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/spawn_manager.rb:251:in `handle_spawn_application'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_server.rb:317:in `__send__'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_server.rb:317:in `main_loop'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/lib/passenger/abstract_server.rb:168:in `start_synchronously'
    /usr/local/lib/ruby/gems/1.8/gems/passenger-2.0.6/bin/passenger-spawn-server:46

Actions #6

Updated by Egor Morozov over 15 years ago

Any ideas how to resolve the problem?

Actions #7

Updated by Jean-Philippe Lang over 15 years ago

As Jean-Baptiste said, you have to add this at the end of config/environment.rb:

ActionController::AbstractRequest.relative_url_root = "/redmine"

And restart the app. It perfectly works.

Actions #8

Updated by Egor Morozov over 15 years ago

I know that I need to restart the app after changes. I did it and it still doesn't work. When I try to open any real file (like *.css) I get 404 Not Found error from Redmine.

Actions #9

Updated by Egor Morozov over 15 years ago

  • Status changed from New to Resolved

Strange... it started working after svn update.

Anyway, thanks for your help.

Actions #10

Updated by Jean-Philippe Lang over 15 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF