Skip to content

Commit

Permalink
Merge branch 'master' into dashboard-fetch-rate-limit
Browse files Browse the repository at this point in the history
  • Loading branch information
NissesSenap committed May 8, 2022
2 parents eaf1495 + a1245e3 commit 537910e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions controllers/model/grafanaService.go
Expand Up @@ -70,9 +70,11 @@ func GetGrafanaPort(cr *v1alpha1.Grafana) int {
func getServicePorts(cr *v1alpha1.Grafana, currentState *v1.Service) []v1.ServicePort {
intPort := int32(GetGrafanaPort(cr))
nodePort := int32(0)
for _, nPort := range cr.Spec.Service.Ports {
if nPort.Port == 3000 {
nodePort = nPort.NodePort
if cr.Spec.Service != nil {
for _, nPort := range cr.Spec.Service.Ports {
if nPort.Port == 3000 {
nodePort = nPort.NodePort
}
}
}
defaultPorts := []v1.ServicePort{
Expand Down

0 comments on commit 537910e

Please sign in to comment.