diff --git a/bitnami/grafana/Chart.yaml b/bitnami/grafana/Chart.yaml index 80f1a4cd2..60a428cf6 100644 --- a/bitnami/grafana/Chart.yaml +++ b/bitnami/grafana/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 name: grafana -version: 0.0.6 +version: 1.0.0 appVersion: "6.3.3" description: Grafana is an open source, feature rich metrics dashboard and graph editor for Graphite, Elasticsearch, OpenTSDB, Prometheus and InfluxDB. keywords: diff --git a/bitnami/grafana/README.md b/bitnami/grafana/README.md index 6438eb4c6..92909e2d5 100644 --- a/bitnami/grafana/README.md +++ b/bitnami/grafana/README.md @@ -49,75 +49,79 @@ The command removes all the Kubernetes components associated with the chart and The following tables lists the configurable parameters of the grafana chart and their default values. -| Parameter | Description | Default | -| ------------------------------------------- | ------------------------------------------------------------------------------------------- | ------------------------------------------------------- | -| `global.imageRegistry` | Global Docker image registry | `nil` | -| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` (does not add image pull secrets to deployed pods) | -| `image.registry` | Grafana image registry | `docker.io` | -| `image.repository` | Grafana image name | `bitnami/grafana` | -| `image.tag` | Grafana image tag | `{TAG_NAME}` | -| `image.pullPolicy` | Grafana image pull policy | `IfNotPresent` | -| `image.pullSecrets` | Specify docker-registry secret names as an array | `[]` (does not add image pull secrets to deployed pods) | -| `nameOverride` | String to partially override grafana.fullname template with a string (will prepend the release name) | `nil` | -| `fullnameOverride` | String to fully override grafana.fullname template with a string | `nil` | -| `replicaCount` | Number of replicas of the Grafana Pod | `1` | -| `updateStrategy` | Update strategy for deployment | `{type: "RollingUpdate"}` | -| `schedulerName` | Alternative scheduler | `nil` | -| `admin.user` | Grafana admin username | `admin` | -| `admin.password` | Grafana admin password | Randomly generated | -| `smtp.enabled` | Enable SMTP configuration | `false` | -| `smtp.existingSecret` | Secret with SMTP credentials | `nil` | -| `smtp.existingSecretUserKey` | Key which value is the SMTP user in the SMTP secret | `user` | -| `smtp.existingSecretPasswordKey` | Key which values is the SMTP password in the SMTP secret | `password` | -| `plugins` | Grafana plugins to be installed in deployment time separated by commas | `nil` | -| `ldap.enabled` | Enable LDAP for Grafana | `false` | -| `ldap.allowSignUp` | Allows LDAP sign up for Grafana | `false` | -| `ldap.configMapName` | Name of the ConfigMap with the LDAP configuration file for Grafana | `nil` | -| `extraEnvVars` | Array containing extra env vars to configure Grafana | `nil` | -| `extraConfigmaps` | Array to mount extra ConfigMaps to configure Grafana | `nil` | -| `config.useGrafanaIniFile` | Allows to load a `grafana.ini` file | `false` | -| `config.grafanaIniConfigMap` | Name of the ConfigMap containing the `grafana.ini` file | `nil` | -| `config.useCustomIniFile` | Allows to load a `custom.ini` file | `false` | -| `config.customIniConfigMap` | Name of the ConfigMap containing the `custom.ini` file | `nil` | -| `dashboardsProvider.enabled` | Enable the use of a Grafana dashboard provider | `false` | -| `dashboardsProvider.configMapName` | Name of a ConfigMap containing a custom dashboard provider | `nil` | -| `dashboardsConfigMaps` | Array with the names of a series of ConfigMaps containing dashboards files | `nil` | -| `datasources.secretName` | Secret name containing custom datasource files | `nil` | -| `persistence.enabled` | Enable persistence | `true` | -| `presistence.storageClass` | Storage class to use with the PVC | `nil` | -| `persistence.accessMode` | Access mode to the PV | `ReadWriteOnce` | -| `persistence.size` | Size for the PV | `10Gi` | -| `livenessProbe.enabled` | Enable/disable the Liveness probe | `true` | -| `livenessProbe.initialDelaySeconds` | Delay before liveness probe is initiated | `60` | -| `livenessProbe.periodSeconds` | How often to perform the probe | `10` | -| `livenessProbe.timeoutSeconds` | When the probe times out | `5` | -| `livenessProbe.successThreshold` | Minimum consecutive successes for the probe to be considered successful after having failed.| `1` | -| `livenessProbe.failureThreshold` | Minimum consecutive failures for the probe to be considered failed after having succeeded. | `6` | -| `readinessProbe.enabled` | Enable/disable the Readiness probe | `true` | -| `readinessProbe.initialDelaySeconds` | Delay before readiness probe is initiated | `5` | -| `readinessProbe.periodSeconds` | How often to perform the probe | `10` | -| `readinessProbe.timeoutSeconds` | When the probe times out | `5` | -| `readinessProbe.failureThreshold` | Minimum consecutive failures for the probe to be considered failed after having succeeded. | `6` | -| `readinessProbe.successThreshold` | Minimum consecutive successes for the probe to be considered successful after having failed.| `1` | -| `service.type` | Kubernetes Service type | `ClusterIP` | -| `service.webPort` | Grafana client port | `80` | -| `service.clusterPort` | Grafana cluster port | `7077` | -| `service.nodePort` | Port to bind to for NodePort service type (client port) | `nil` | -| `service.annotations` | Annotations for Grafana service | `{}` | -| `service.loadBalancerIP` | loadBalancerIP if Grafana service type is `LoadBalancer` | `nil` | -| `ingress.enabled` | Enable the use of the ingress controller to access the web UI | `false` | -| `ingress.annotations` | Annotations for the Grafana Ingress | `{}` | -| `ingress.hosts` | Add hosts to the ingress controller with name and path | `name: grafana.local`, `path: /` | -| `ingress.tls` | Configure TLS for the Grafana Ingress | `[]` | -| `securityContext.enabled` | Enable securityContext on for Granafa deployment | `true` | -| `securityContext.runAsUser` | User for the security context | `1001` | -| `securityContext.fsGroup` | Group to configure permissions for volumes | `1001` | -| `securityContext.runAsNonRoot` | Run containers as non-root users | `true` | -| `resources` | Configure resource requests and limits | `nil` | -| `nodeSelector` | Node labels for pod assignment | `{}` | -| `tolerations` | Tolerations for pod assignment | `[]` | -| `affinity` | Affinity for pod assignment | `{}` | -| `podAnnotations` | Pod annotations | `{}` | +| Parameter | Description | Default | +| ------------------------------------ | ---------------------------------------------------------------------------------------------------- | ------------------------------------------------------- | +| `global.imageRegistry` | Global Docker image registry | `nil` | +| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` (does not add image pull secrets to deployed pods) | +| `image.registry` | Grafana image registry | `docker.io` | +| `image.repository` | Grafana image name | `bitnami/grafana` | +| `image.tag` | Grafana image tag | `{TAG_NAME}` | +| `image.pullPolicy` | Grafana image pull policy | `IfNotPresent` | +| `image.pullSecrets` | Specify docker-registry secret names as an array | `[]` (does not add image pull secrets to deployed pods) | +| `nameOverride` | String to partially override grafana.fullname template with a string (will prepend the release name) | `nil` | +| `fullnameOverride` | String to fully override grafana.fullname template with a string | `nil` | +| `replicaCount` | Number of replicas of the Grafana Pod | `1` | +| `updateStrategy` | Update strategy for deployment | `{type: "RollingUpdate"}` | +| `schedulerName` | Alternative scheduler | `nil` | +| `admin.user` | Grafana admin username | `admin` | +| `admin.password` | Grafana admin password | Randomly generated | +| `smtp.enabled` | Enable SMTP configuration | `false` | +| `smtp.existingSecret` | Secret with SMTP credentials | `nil` | +| `smtp.existingSecretUserKey` | Key which value is the SMTP user in the SMTP secret | `user` | +| `smtp.existingSecretPasswordKey` | Key which values is the SMTP password in the SMTP secret | `password` | +| `plugins` | Grafana plugins to be installed in deployment time separated by commas | `nil` | +| `ldap.enabled` | Enable LDAP for Grafana | `false` | +| `ldap.allowSignUp` | Allows LDAP sign up for Grafana | `false` | +| `ldap.configMapName` | Name of the ConfigMap with the LDAP configuration file for Grafana | `nil` | +| `extraEnvVars` | Array containing extra env vars to configure Grafana | `nil` | +| `extraConfigmaps` | Array to mount extra ConfigMaps to configure Grafana | `nil` | +| `config.useGrafanaIniFile` | Allows to load a `grafana.ini` file | `false` | +| `config.grafanaIniConfigMap` | Name of the ConfigMap containing the `grafana.ini` file | `nil` | +| `config.useCustomIniFile` | Allows to load a `custom.ini` file | `false` | +| `config.customIniConfigMap` | Name of the ConfigMap containing the `custom.ini` file | `nil` | +| `dashboardsProvider.enabled` | Enable the use of a Grafana dashboard provider | `false` | +| `dashboardsProvider.configMapName` | Name of a ConfigMap containing a custom dashboard provider | `nil` | +| `dashboardsConfigMaps` | Array with the names of a series of ConfigMaps containing dashboards files | `nil` | +| `datasources.secretName` | Secret name containing custom datasource files | `nil` | +| `persistence.enabled` | Enable persistence | `true` | +| `presistence.storageClass` | Storage class to use with the PVC | `nil` | +| `persistence.accessMode` | Access mode to the PV | `ReadWriteOnce` | +| `persistence.size` | Size for the PV | `10Gi` | +| `livenessProbe.enabled` | Enable/disable the Liveness probe | `true` | +| `livenessProbe.initialDelaySeconds` | Delay before liveness probe is initiated | `60` | +| `livenessProbe.periodSeconds` | How often to perform the probe | `10` | +| `livenessProbe.timeoutSeconds` | When the probe times out | `5` | +| `livenessProbe.successThreshold` | Minimum consecutive successes for the probe to be considered successful after having failed. | `1` | +| `livenessProbe.failureThreshold` | Minimum consecutive failures for the probe to be considered failed after having succeeded. | `6` | +| `readinessProbe.enabled` | Enable/disable the Readiness probe | `true` | +| `readinessProbe.initialDelaySeconds` | Delay before readiness probe is initiated | `5` | +| `readinessProbe.periodSeconds` | How often to perform the probe | `10` | +| `readinessProbe.timeoutSeconds` | When the probe times out | `5` | +| `readinessProbe.failureThreshold` | Minimum consecutive failures for the probe to be considered failed after having succeeded. | `6` | +| `readinessProbe.successThreshold` | Minimum consecutive successes for the probe to be considered successful after having failed. | `1` | +| `service.type` | Kubernetes Service type | `ClusterIP` | +| `service.webPort` | Grafana client port | `80` | +| `service.clusterPort` | Grafana cluster port | `7077` | +| `service.nodePort` | Port to bind to for NodePort service type (client port) | `nil` | +| `service.annotations` | Annotations for Grafana service | `{}` | +| `service.loadBalancerIP` | loadBalancerIP if Grafana service type is `LoadBalancer` | `nil` | +| `ingress.enabled` | Enable the use of the ingress controller to access the web UI | `false` | +| `ingress.certManager` | Add annotations for cert-manager | `false` | +| `ingress.annotations` | Annotations for the Grafana Ingress | `{}` | +| `ingress.hosts[0].name` | Hostname to your Grafana installation | `grafana.local` | +| `ingress.hosts[0].paths` | Path within the url structure | `["/"]` | +| `ingress.hosts[0].tls` | Utilize TLS backend in ingress | `false` | +| `ingress.hosts[0].tlsHosts` | Array of TLS hosts for ingress record (defaults to `ingress.hosts[0].name` if `nil`) | `nil` | +| `ingress.hosts[0].tlsSecret` | TLS Secret (certificates) | `grafana.local-tls` | +| `securityContext.enabled` | Enable securityContext on for Granafa deployment | `true` | +| `securityContext.runAsUser` | User for the security context | `1001` | +| `securityContext.fsGroup` | Group to configure permissions for volumes | `1001` | +| `securityContext.runAsNonRoot` | Run containers as non-root users | `true` | +| `resources` | Configure resource requests and limits | `nil` | +| `nodeSelector` | Node labels for pod assignment | `{}` | +| `tolerations` | Tolerations for pod assignment | `[]` | +| `affinity` | Affinity for pod assignment | `{}` | +| `podAnnotations` | Pod annotations | `{}` | Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, diff --git a/bitnami/grafana/templates/ingress.yaml b/bitnami/grafana/templates/ingress.yaml index 51796eafc..c99a5abdc 100644 --- a/bitnami/grafana/templates/ingress.yaml +++ b/bitnami/grafana/templates/ingress.yaml @@ -12,26 +12,31 @@ metadata: {{- toYaml . | nindent 4 }} {{- end }} spec: -{{- if .Values.ingress.tls }} - tls: - {{- range .Values.ingress.tls }} - - hosts: - {{- range .hosts }} - - {{ . | quote }} - {{- end }} - secretName: {{ .secretName }} - {{- end }} -{{- end }} rules: {{- range .Values.ingress.hosts }} - - host: {{ .host | quote }} + - host: {{ .name | quote }} http: paths: - {{- range .paths }} + {{- $paths := default (list "/") .paths }} + {{- range $paths }} - path: {{ . }} backend: serviceName: {{ include "grafana.fullname" $ }} servicePort: http {{- end }} {{- end }} + tls: + {{- range .Values.ingress.hosts }} + {{- if .tls }} + - hosts: + {{- if .tlsHosts }} + {{- range $host := .tlsHosts }} + - {{ $host }} + {{- end }} + {{- else }} + - {{ .name }} + {{- end }} + secretName: {{ .tlsSecret }} + {{- end }} +{{- end }} {{- end }} diff --git a/bitnami/grafana/values-production.yaml b/bitnami/grafana/values-production.yaml index edc6462c6..ca1c8ac6a 100644 --- a/bitnami/grafana/values-production.yaml +++ b/bitnami/grafana/values-production.yaml @@ -224,15 +224,21 @@ ingress: ## The list of hostnames to be covered with this ingress record. ## Most likely this will be just one host, but in the event more hosts are needed, this is an array hosts: - - host: grafana.local + - name: grafana.local paths: ["/"] - ## The tls configuration for the ingress - ## see: https://kubernetes.io/docs/concepts/services-networking/ingress/#tls - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local + ## Set this to true in order to enable TLS on the ingress record + tls: false + + ## Optionally specify the TLS hosts for the ingress record + ## Useful when the Ingress controller supports www-redirection + ## If not specified, the above host name will be used + # tlsHosts: + # - www.grafana.local + # - grafana.local + + ## If TLS is set to true, you must declare what secret will store the key/certificate for TLS + tlsSecret: grafana.local-tls ## SecurityContext configuration ## diff --git a/bitnami/grafana/values.yaml b/bitnami/grafana/values.yaml index 5d3162890..f89aa97f2 100644 --- a/bitnami/grafana/values.yaml +++ b/bitnami/grafana/values.yaml @@ -224,15 +224,21 @@ ingress: ## The list of hostnames to be covered with this ingress record. ## Most likely this will be just one host, but in the event more hosts are needed, this is an array hosts: - - host: grafana.local + - name: grafana.local paths: ["/"] - ## The tls configuration for the ingress - ## see: https://kubernetes.io/docs/concepts/services-networking/ingress/#tls - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local + ## Set this to true in order to enable TLS on the ingress record + tls: false + + ## Optionally specify the TLS hosts for the ingress record + ## Useful when the Ingress controller supports www-redirection + ## If not specified, the above host name will be used + # tlsHosts: + # - www.grafana.local + # - grafana.local + + ## If TLS is set to true, you must declare what secret will store the key/certificate for TLS + tlsSecret: grafana.local-tls ## SecurityContext configuration ##