1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2024-12-15 17:51:20 +00:00
kyverno/pkg/config/tls.go
Charles-Edouard Brétéché 0f9fe30c08
feat: allow overriding ca and tls secret names (#8137)
* feat: allow overriding ca and tls secret names

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

* fix

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

---------

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
2023-08-28 14:05:49 +00:00

15 lines
344 B
Go

package config
import "fmt"
func InClusterServiceName(commonName string, namespace string) string {
return commonName + "." + namespace + ".svc"
}
func DnsNames(commonName string, namespace string) []string {
return []string{
commonName,
fmt.Sprintf("%s.%s", commonName, namespace),
InClusterServiceName(commonName, namespace),
}
}