Skip to content

Commit

Permalink
Merge pull request #1713 from amimof/add-svc-to-internal-adminurl
Browse files Browse the repository at this point in the history
Adds `.svc` to internal grafana `adminUrl`
  • Loading branch information
theSuess authored Oct 14, 2024
2 parents 5851fe4 + 53b9c17 commit eb1e1a8
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@ func (r *ServiceReconciler) Reconcile(ctx context.Context, cr *v1beta1.Grafana,

// try to assign the admin url
if !cr.PreferIngress() {
status.AdminUrl = fmt.Sprintf("%v://%v.%v:%d", getGrafanaServerProtocol(cr), service.Name, cr.Namespace,
// .svc suffix needed for automatic openshift certificates: https://docs.openshift.com/container-platform/4.17/security/certificates/service-serving-certificate.html#add-service-certificate_service-serving-certificate
status.AdminUrl = fmt.Sprintf("%v://%v.%v.svc:%d", getGrafanaServerProtocol(cr), service.Name, cr.Namespace,
int32(GetGrafanaPort(cr)))
}

Expand Down

0 comments on commit eb1e1a8

Please sign in to comment.