forked from OpenNeo/impress
mount the resque app regardless of admin status if in development
This commit is contained in:
parent
1070778398
commit
625f1ee8b4
1 changed files with 9 additions and 1 deletions
|
@ -103,7 +103,15 @@ OpenneoImpressItems::Application.routes.draw do
|
||||||
match '/sitemap.xml' => 'sitemap#index', :as => :sitemap, :format => :xml
|
match '/sitemap.xml' => 'sitemap#index', :as => :sitemap, :format => :xml
|
||||||
match '/robots.txt' => 'sitemap#robots', :as => :robots, :format => :text
|
match '/robots.txt' => 'sitemap#robots', :as => :robots, :format => :text
|
||||||
|
|
||||||
authenticated :user, lambda { |u| u.admin? } do
|
def mount_resque
|
||||||
mount Resque::Server, :at => '/resque'
|
mount Resque::Server, :at => '/resque'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if Rails.env.development?
|
||||||
|
mount_resque
|
||||||
|
else
|
||||||
|
authenticated :user, lambda { |u| u.admin? } do
|
||||||
|
mount_resque
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
Loading…
Reference in a new issue