Ever since VMs and Templates/Images are separated and distinguished by the base_model name, namely Vm and MiqTemplate, the compliance check for templates is broken. Yes, you can still create a VM Compliance Check Policy and assign it to a template, but the compliance check will not go through.
Another related issue is scheduling a compliance check task for templates. Currently when create a new schedule task the available actions include VM Analysis, Template Analysis, VM Compliance Check, but NO Template Compliance Check. For VM Compliance Check, you can select a single VM using VM Selection Filter, but you cannot select a template. Thus there is no way to schedule a compliance check for a template.
This topic is to discuss the proper way to reenable template compliance check. There are two solutions. The first is to completely separate template from VM. The UI needs to add Template Compliance Policies under Control/Explore/Policies/Compliance Policies. Similarly when adding a new Schedule, the Action drop down list should provide a new option Template Compliance Check. This makes sense since VM Analysis and Template Analysis are already separate options there.
The second solution is to treat VM and Template the same when performing a compliance check. This requires some refactoring at the back end. In addition the UI needs to rename VM Compliance Check/Policies to VM and Template Compliance Check/Policies, it also needs to enable selection of a template when scheduling a compliance check task.