cri: add ignore_rdt_not_enabled_errors config option

Enabling this option effectively causes RDT class of a container to be a
soft requirement. If RDT support has not been enabled the RDT class
setting will not have any effect.

Signed-off-by: Markus Lehtonen <markus.lehtonen@intel.com>
This commit is contained in:
Markus Lehtonen
2021-09-24 13:00:51 +03:00
parent eba1048163
commit 9c2e3835fa
5 changed files with 23 additions and 4 deletions

View File

@@ -257,7 +257,7 @@ func (c *criService) containerSpec(
supplementalGroups := securityContext.GetSupplementalGroups()
// Get RDT class
rdtClass, err := rdtClassFromAnnotations(config.GetMetadata().GetName(), config.Annotations, sandboxConfig.Annotations)
rdtClass, err := c.rdtClassFromAnnotations(config.GetMetadata().GetName(), config.Annotations, sandboxConfig.Annotations)
if err != nil {
return nil, errors.Wrap(err, "failed to set RDT class")
}