Refactor validate_media? to be hookable
Katello plugin needs to hook into validate_media? method. When Bootdisk added new provisioning method, there are now two methods which needs media to be present: build (pxe) and boodisk. Katello needs to disable media validation when content source is set, but this can't be done via single hook point, because either build or bootdisk method is always true:
super || (managed && bootdisk_build? && build?)
We need to refactor this in a way that katello can hook it. One idea is to create method for each individual method:
- validate_image_media? (returns always false)
- validate_bootdisk_media? (created by bootdisk plugin)
So Katello can hook individually. But in this case initializers in Katello must be changed - host extensions must be called after boodisk creates the method (perhaps via after_initialize block).