Allow empty services in Kubernetes CRD

This commit is contained in:
Tom Moulard 2022-03-07 11:08:07 +01:00 committed by GitHub
parent c7b24f4e9c
commit 63bb770b9c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 384 additions and 28 deletions

View file

@ -135,7 +135,7 @@ func (p *Provider) loadUDPServers(client Client, namespace string, svc v1alpha1.
return nil, errors.New("endpoints not found")
}
if len(endpoints.Subsets) == 0 {
if len(endpoints.Subsets) == 0 && !p.AllowEmptyServices {
return nil, errors.New("subset not found")
}