From 23c7befc0023e9cd7968403f5a3f77e381de6686 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Qi=CE=BC=24hi=D0=AFu=C3=AD?= <39378935+srstack@users.noreply.github.com> Date: Tue, 7 Dec 2021 14:41:55 +0800 Subject: [PATCH] cluster: No port conflicts were detected during scale-out of the cluster imported from ansible (#1656) --- pkg/cluster/spec/validate.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/pkg/cluster/spec/validate.go b/pkg/cluster/spec/validate.go index 015b99606a..e751903366 100644 --- a/pkg/cluster/spec/validate.go +++ b/pkg/cluster/spec/validate.go @@ -642,10 +642,7 @@ func (s *Specification) portConflictsDetect() error { compSpecs := topoSpec.Field(i) for index := 0; index < compSpecs.Len(); index++ { compSpec := reflect.Indirect(compSpecs.Index(index)) - // skip nodes imported from TiDB-Ansible - if compSpec.Addr().Interface().(InstanceSpec).IsImported() { - continue - } + // check hostname host := compSpec.FieldByName("Host").String() cfg := strings.Split(topoType.Field(i).Tag.Get("yaml"), ",")[0] // without meta