From 3600fa351da5169f922e4849277f1fc277cbeda1 Mon Sep 17 00:00:00 2001 From: Zexi Li Date: Mon, 16 Sep 2019 20:19:29 +0800 Subject: [PATCH] scheduler: fix baremetal disk and storage not match --- pkg/scheduler/algorithm/predicates/disk_schedtag_predicate.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/scheduler/algorithm/predicates/disk_schedtag_predicate.go b/pkg/scheduler/algorithm/predicates/disk_schedtag_predicate.go index d33cfd5716..b5ba7b45af 100644 --- a/pkg/scheduler/algorithm/predicates/disk_schedtag_predicate.go +++ b/pkg/scheduler/algorithm/predicates/disk_schedtag_predicate.go @@ -105,7 +105,7 @@ func (p *DiskSchedtagPredicate) IsResourceFitInput(u *core.Unit, c core.Candidat if c.Getter().ResourceType() == computeapi.HostResourceTypePrepaidRecycle { return nil } - if len(d.Backend) != 0 { + if len(d.Backend) != 0 && storage.StorageType != computeapi.STORAGE_BAREMETAL { if storage.StorageType != d.Backend { return &FailReason{ fmt.Sprintf("Storage %s backend %s != %s", storage.Name, storage.StorageType, d.Backend),