Skip to content

Commit

Permalink
Update routes.rb
Browse files Browse the repository at this point in the history
Force auth for sidekiq web ui and move within /admin
  • Loading branch information
ewlarson committed Oct 18, 2023
1 parent c202aa3 commit 8329691
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
get 'help', :to => redirect('https://sites.google.com/umn.edu/btaa-gdp/help')
get 'robots.:format' => 'robots#robots'

# Sidekiq - Uncomment and restart app to view sidekiq dashboard
mount Sidekiq::Web => "/sidekiq"

# Feedback
mount PointlessFeedback::Engine, :at => '/feedback'

Expand Down Expand Up @@ -99,6 +96,11 @@
end

namespace :admin do

authenticate :user, ->(user) { user.admin? } do
mount Sidekiq::Web => "/sidekiq"
end

devise_for :users, controllers: {invitations: "devise/invitations"}, skip: [:registrations]
# Root
root to: "documents#index"
Expand Down

0 comments on commit 8329691

Please sign in to comment.