Skip to content
Snippets Groups Projects
Verified Commit 3857c436 authored by Alexander Olofsson's avatar Alexander Olofsson
Browse files

Ensure discovery supports WDS boot

parent 421ac132
No related branches found
No related tags found
No related merge requests found
......@@ -83,9 +83,13 @@ module ForemanWds
HostsController.include ForemanWds::HostsControllerExtensions
UnattendedController.prepend ForemanWds::UnattendedControllerExtensions
ComputeResource.providers.each do |_k, const|
ComputeResource.providers.each_value do |const|
Kernel.const_get(const).send(:prepend, ForemanWds::ComputeResourceExtensions)
end
if Foreman::Plugin.installed?('foreman_discovery')
DiscoveredHostsController.include ForemanWds::HostsControllerExtensions
end
rescue StandardError => e
Rails.logger.fatal "foreman_wds: skipping engine hook (#{e})"
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment