Actions
Bug #20397
closedActionController::UrlGenerationError in HostsController#play_roles when playing role on a host
Description
2017-07-25T09:13:13 e0b7eed7 [app] [I] Completed 500 Internal Server Error in 9ms (ActiveRecord: 1.5ms) 2017-07-25T09:13:13 e0b7eed7 [app] [F] | ActionController::UrlGenerationError (No route matches {:action=>"show", :controller=>"hosts", :id=>nil} missing required keys: [:id]): | config/initializers/routing_hash_for.rb:11:in `block (2 levels) in define_url_helper' | /home/ares/Projekty/Zdrojaky/foreman_ansible/app/controllers/foreman_ansible/concerns/hosts_controller_extensions.rb:14:in `rescue in play_roles' | /home/ares/Projekty/Zdrojaky/foreman_ansible/app/controllers/foreman_ansible/concerns/hosts_controller_extensions.rb:9:in `play_roles' | app/controllers/concerns/application_shared.rb:15:in `set_timezone' | app/models/concerns/foreman/thread_session.rb:32:in `clear_thread' | app/controllers/concerns/foreman/controller/topbar_sweeper.rb:12:in `set_topbar_sweeper_controller' | lib/middleware/catch_json_parse_errors.rb:8:in `call' | lib/middleware/tagged_logging.rb:18:in `call'
This is caused by the wrongly defined permission override so when we try to find_resource
it fails on unknown permission for play_roles
action. I'm not sure when this started to be a problem since the code is there for more than a year, but it's clear it could not have worked correctly.
Updated by The Foreman Bot over 7 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/theforeman/foreman_ansible/pull/92 added
Updated by Marek Hulán over 7 years ago
Btw the reproduced was just trying to play roles on a specific host. My Foreman and foreman_ansible versions are develop/master checkouts.
Updated by Anonymous over 7 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset foreman_ansible|7a6f88301fc091742c815d1566da54c2da7f2b81.
Actions