Add https scheme

[ZITADOPER-1]
This commit is contained in:
Haim Kortovich
2024-05-08 16:07:34 -05:00
parent 0407a4b38a
commit 7bc10a390a

View File

@@ -51,7 +51,11 @@ func GetAuthority(zitadel *zitadelv1alpha1.ZitadelCluster) string {
} }
func GetIssuer(zitadel *zitadelv1alpha1.ZitadelCluster) string { func GetIssuer(zitadel *zitadelv1alpha1.ZitadelCluster) string {
return fmt.Sprintf("http://%s:%d", zitadel.Spec.Host, zitadel.Spec.ExternalPort) scheme := "http"
if zitadel.Spec.ExternalSecure {
scheme = "https"
}
return fmt.Sprintf("%s://%s:%d", scheme, zitadel.Spec.Host, zitadel.Spec.ExternalPort)
} }
func GetAPI(zitadel *zitadelv1alpha1.ZitadelCluster) string { func GetAPI(zitadel *zitadelv1alpha1.ZitadelCluster) string {