From 86722cf4e25b6ca5656bb6e49cd429ba70e05570 Mon Sep 17 00:00:00 2001 From: Pedro Juarez Date: Mon, 5 Aug 2024 18:47:13 -0700 Subject: [PATCH] Remove index-based pool name verification (#2164) Build of MINIO_ARGS from Pool status is incomplete and leads to duplicated args names when a pool doesn't have the name `spec.pools.*.name`. Signed-off-by: pjuarezd --- pkg/apis/minio.min.io/v2/helper.go | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/pkg/apis/minio.min.io/v2/helper.go b/pkg/apis/minio.min.io/v2/helper.go index cfd3ef3330a..b68517983f9 100644 --- a/pkg/apis/minio.min.io/v2/helper.go +++ b/pkg/apis/minio.min.io/v2/helper.go @@ -413,13 +413,8 @@ func (t *Tenant) GenBearerToken(accessKey, secretKey string) string { // MinIOHosts returns the domain names in ellipses format created for current Tenant func (t *Tenant) MinIOHosts() (hosts []string) { // Create the ellipses style URL - for pi, pool := range t.Spec.Pools { - // determine the proper statefulset name + for _, pool := range t.Spec.Pools { ssName := t.PoolStatefulsetName(&pool) - if len(t.Status.Pools) > pi { - ssName = t.Status.Pools[pi].SSName - } - if pool.Servers == 1 { hosts = append(hosts, fmt.Sprintf("%s-%s.%s.%s.svc.%s", ssName, "0", t.MinIOHLServiceName(), t.Namespace, GetClusterDomain())) } else {