I am using Ruby On Rails 3.0.9 and everything works fine on Development env. When I switch to Production env or upload it to our server, after logging in, I return to the same login page. When I check the log, I see the following:
Started POST "/users/login" for 127.0.0.1 at Thu Oct 03 16:48:13 -0300 2013
Processing by UserSessionsController
Parameters: {"user"=>{"password"=>"[FILTERED]", "login"=>"demo_admin"}, "utf8"=>"✓", "authenticity_token"=>"+7AEoVXZ9XiagEymVUnOhFHnck4rgDu883E/ySMlCxQ="}
Redirected to http:
Completed 302 Found in 111ms
Started GET "/admin" for 127.0.0.1 at Thu Oct 03 16:48:13 -0300 2013
Processing by Admin::DashboardController
Completed 401 Unauthorized in 1ms
I use the authorization_rules file for access control, but I have no problem with Dev env, as I said.
If I set a breakpoint in action admin/dashboard#index, it will not be executed, as it will not be reached. It breaks into an httpserver file (I debugged it step by step), but I can’t understand why it works on Dev and not on Prod env.
Please, help.
Thanks Brian
UPDATE
, ApplicationController before_filter, check_plan_features, , , unless current_user.blank? #redirects to Admin section.
, , Devise, current_user , admin , current_user null, , , - . , , , .