Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion charts/linkerd2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,6 @@ Kubernetes: `>=1.13.0-0`
| global.controllerNamespaceLabel | string | `"linkerd.io/control-plane-ns"` | Control plane label. Do not edit |
| global.createdByAnnotation | string | `"linkerd.io/created-by"` | Annotation label for the proxy create. Do not edit. |
| global.enableEndpointSlices | bool | `false` | enables the use of EndpointSlice informers for the destination service; enableEndpointSlices should be set to true only if EndpointSlice K8s feature gate is on; the feature is still experimental. |
| global.grafanaUrl | string | `""` | url of external grafana instance with reverse proxy configured. |
| global.identityTrustAnchorsPEM | string | `""` | Trust root certificate (ECDSA). It must be provided during install. |
| global.identityTrustDomain | string | `"cluster.local"` | Trust domain used for identity |
| global.imagePullPolicy | string | `"IfNotPresent"` | Docker image pull policy |
Expand Down
3 changes: 0 additions & 3 deletions charts/linkerd2/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ global:
# -- Trust domain used for identity
identityTrustDomain: *cluster_domain

# -- url of external grafana instance with reverse proxy configured.
grafanaUrl: ""

# -- Additional annotations to add to all pods
podAnnotations: {}

Expand Down
1 change: 1 addition & 0 deletions viz/charts/linkerd-viz/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ Kubernetes: `>=1.13.0-0`
| grafana.resources.cpu.request | string | `nil` | Amount of CPU units that the grafana container requests |
| grafana.resources.memory.limit | string | `nil` | Maximum amount of memory that grafana container can use |
| grafana.resources.memory.request | string | `nil` | Amount of memory that the grafana container requests |
| grafanaUrl | string | `""` | url of external grafana instance with reverse proxy configured. |
| identityTrustDomain | string | `"cluster.local"` | Trust domain used for identity |
| imagePullSecrets | list | `[]` | For Private docker registries, authentication is needed. Registry secrets are applied to the respective service accounts |
| installNamespace | bool | `true` | Set to false when installing in a custom namespace. |
Expand Down
6 changes: 6 additions & 0 deletions viz/charts/linkerd-viz/templates/namespace.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,11 @@ metadata:
labels:
{{.Values.extensionAnnotation}}: linkerd-viz
annotations:
{{- if .Values.prometheusUrl }}
viz.linkerd.io/external-prometheus: {{.Values.prometheusUrl}}
{{- end }}
{{- if .Values.grafanaUrl }}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This logic i.e assuming linkerd-grafana is presently based on the absence of this annotation does not really work with grafana because both being absent case is allowed here. Should we make disabled an explicit annotation then?

viz.linkerd.io/external-grafana: {{.Values.grafanaUrl}}
{{- end }}
{{.Values.proxyInjectAnnotation}}: enabled
{{ end -}}
3 changes: 3 additions & 0 deletions viz/charts/linkerd-viz/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ enablePodAntiAffinity: false
# -- url of external prometheus instance
prometheusUrl: ""

# -- url of external grafana instance with reverse proxy configured.
grafanaUrl: ""

# -- url of external jaeger instance
# Set this to `jaeger.linkerd-jaeger.svc.<clusterDomain>` if you plan to use jaeger extension
jaegerUrl: ""
Expand Down
7 changes: 7 additions & 0 deletions viz/cmd/install_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,13 @@ func TestRender(t *testing.T) {
},
"install_proxy_resources.golden",
},
{
map[string]interface{}{
"grafana": map[string]interface{}{"enabled": false},
"grafanaUrl": "external-grafana.com",
},
"install_grafana_disabled.golden",
},
}

for i, tc := range testCases {
Expand Down
Loading