From a5f8a1f3c04496c529dab35f2a895b15df2c6d9d Mon Sep 17 00:00:00 2001 From: Jose Santorum Date: Thu, 16 May 2024 19:55:42 +0200 Subject: [PATCH] fix: add motive-cache chart --- charts/motive-cache/Chart.yaml | 2 +- charts/motive-cache/README.md | 18 +++++++++--------- charts/motive-cache/templates/service.yaml | 2 +- .../templates/varnish-cluster.yaml | 2 +- charts/motive-cache/values.yaml | 15 +++++++-------- 5 files changed, 19 insertions(+), 20 deletions(-) diff --git a/charts/motive-cache/Chart.yaml b/charts/motive-cache/Chart.yaml index 87a0ccc..db97b72 100644 --- a/charts/motive-cache/Chart.yaml +++ b/charts/motive-cache/Chart.yaml @@ -4,6 +4,6 @@ description: A Helm chart for Kubernetes type: application -version: 0.1.0 +version: 0.1.1 appVersion: "1.0.0" diff --git a/charts/motive-cache/README.md b/charts/motive-cache/README.md index dcbfadc..6fc20fd 100644 --- a/charts/motive-cache/README.md +++ b/charts/motive-cache/README.md @@ -1,6 +1,6 @@ # motive-cache -![Version: 0.1.0](https://img.shields.io/badge/Version-0.1.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.0.0](https://img.shields.io/badge/AppVersion-1.0.0-informational?style=flat-square) +![Version: 0.1.1](https://img.shields.io/badge/Version-0.1.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.0.0](https://img.shields.io/badge/AppVersion-1.0.0-informational?style=flat-square) A Helm chart for Kubernetes @@ -11,8 +11,8 @@ A Helm chart for Kubernetes | affinity | object | `{}` | Similar to the nodeSelector, but slightly different: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#affinity-and-anti-affinity | | backend.namespaces | list | `[]` | Namespace(s) to look for backend pods. By default - namespace the VarnishCluster is deployed to. | | backend.onlyReady | bool | `false` | Include (false, by default) or exclude (true) backend pods from the VCL (.Backends template var). Alters .Backends template variable based on Kubernetes health checks (by default not ready pods are also included in VCL) instead of Varnish health probes. | -| backend.port | string | `"backend-port"` | The port of the backend pods being cached by Varnish. Can be port name or port number. | -| backend.selector | object | `{}` | The selector used to identify the backend Pods. | +| backend.port | string | `""` | The port of the backend pods being cached by Varnish. Can be port name or port number. | +| backend.selector | string | `nil` | The selector used to identify the backend Pods. | | backend.zoneBalancing | object | `{"thresholds":[],"type":"disabled"}` | Controls Varnish backend topology aware routing which can assign weights to backends according to their geographical location. | | backend.zoneBalancing.thresholds | list | `[]` | Array of thresholds objects to determine condition and respective weights to be assigned to backends: threshold, local - local backend weight, remote - remote backend weight | | backend.zoneBalancing.type | string | `"disabled"` | Varnish backend zone-balancing type. Accepted values: disabled, auto, thresholds | @@ -28,15 +28,15 @@ A Helm chart for Kubernetes | ingress.internal.tls | list | `[]` | | | logFormat | string | `"json"` | Format of the logs. Can be json and console. | | logLevel | string | `"info"` | The minimum enabled logging level. Allowed values: debug, info, warn, error, dpanic, panic, fatal. | -| monitoring | object | `{"grafanaDashboard":{"datasourceName":"","enabled":false,"labels":{},"namespace":"","title":""},"prometheusServiceMonitor":{"enabled":true,"labels":{},"namespace":""}}` | The operator monitoring configuration object | +| monitoring | object | `{"grafanaDashboard":{"datasourceName":"","enabled":false,"labels":{},"namespace":"","title":""},"prometheusServiceMonitor":{"enabled":false,"labels":{},"namespace":""}}` | The operator monitoring configuration object | | monitoring.grafanaDashboard | object | `{"datasourceName":"","enabled":false,"labels":{},"namespace":"","title":""}` | A dashboard that can be installed along with the operator and used in grafana. Installed as a ConfigMap. | | monitoring.grafanaDashboard.datasourceName | string | `""` | Name of the Grafana datasource the dashboard should use. (required) | | monitoring.grafanaDashboard.enabled | bool | `false` | Enable or disable the ConfigMap installation. | | monitoring.grafanaDashboard.labels | object | `{}` | ConfigMap labels. Can be used to for discovery by grafana. | | monitoring.grafanaDashboard.namespace | string | `""` | Namespace that the ConfigMap with the dashboard should be installed to. Default to the namespace VarnishCluster is installed to | | monitoring.grafanaDashboard.title | string | `""` | Title of the Grafana dashboard. Default: Varnish (/) | -| monitoring.prometheusServiceMonitor | object | `{"enabled":true,"labels":{},"namespace":""}` | The Prometheus ServiceMonitor that is preconfigured to monitors the operator pods. | -| monitoring.prometheusServiceMonitor.enabled | bool | `true` | Enable or disable ServiceMontitor installation. | +| monitoring.prometheusServiceMonitor | object | `{"enabled":false,"labels":{},"namespace":""}` | The Prometheus ServiceMonitor that is preconfigured to monitors the operator pods. | +| monitoring.prometheusServiceMonitor.enabled | bool | `false` | Enable or disable ServiceMontitor installation. | | monitoring.prometheusServiceMonitor.labels | object | `{}` | ServiceMonitor labels that will be used by Prometheus instance to discover this ServiceMonitor. | | monitoring.prometheusServiceMonitor.namespace | string | `""` | The namespace it should be installed to. Default to the namespace VarnishCluster is installed to | | nameOverride | string | `""` | | @@ -68,9 +68,9 @@ A Helm chart for Kubernetes | varnish.imagePullPolicy | string | `"IfNotPresent"` | Image pull policy for the Varnish container. | | varnish.metricsExporter | object | `{"imagePullPolicy":"IfNotPresent","resources":{"limits":{"memory":"32Mi"},"requests":{"cpu":"10m","memory":"16Mi"}}}` | An object that defines the configuration of a particular Varnish Prometheus metrics exporter being deployed | | varnish.resources | object | `{"limits":{"memory":"192Mi"},"requests":{"cpu":"20m","memory":"128Mi"}}` | Resource requests and limits for Varnish container. | -| vcl | object | `{"configMapName":"tmp","entrypointFileName":"tmp"}` | An object that defines the VCL ConfigMap configuration | -| vcl.configMapName | string | `"tmp"` | Name of the ConfigMap containing the VCL configuration files | -| vcl.entrypointFileName | string | `"tmp"` | The name of the main VCL file | +| vcl | object | `{"configMapName":"","entrypointFileName":""}` | An object that defines the VCL ConfigMap configuration | +| vcl.configMapName | string | `""` | Name of the ConfigMap containing the VCL configuration files | +| vcl.entrypointFileName | string | `""` | The name of the main VCL file | ---------------------------------------------- Autogenerated from chart metadata using [helm-docs v1.11.3](https://github.com/norwoodj/helm-docs/releases/v1.11.3) diff --git a/charts/motive-cache/templates/service.yaml b/charts/motive-cache/templates/service.yaml index 8ecfe8d..0045d21 100644 --- a/charts/motive-cache/templates/service.yaml +++ b/charts/motive-cache/templates/service.yaml @@ -25,5 +25,5 @@ spec: targetPort: ctrl-metrics selector: varnish-component: varnish - statefulset.kubernetes.io/pod-name: {{ include "motive-cache.fullname" $ }}-{{ . }} + statefulset.kubernetes.io/pod-name: {{ include "motive-cache.fullname" $ }}-varnish-{{ . }} {{- end }} \ No newline at end of file diff --git a/charts/motive-cache/templates/varnish-cluster.yaml b/charts/motive-cache/templates/varnish-cluster.yaml index 5d13f08..e2db53d 100644 --- a/charts/motive-cache/templates/varnish-cluster.yaml +++ b/charts/motive-cache/templates/varnish-cluster.yaml @@ -107,5 +107,5 @@ spec: {{- end }} vcl: # required - configMapName: {{ .Values.vcl.configMapName | required ".Values.vcl.configMapName is required." }} + configMapName: {{ tpl (.Values.vcl.configMapName | required ".Values.vcl.configMapName is required.") $ }} entrypointFileName: {{ .Values.vcl.entrypointFileName | required ".Values.vcl.entrypointFileName is required." }} diff --git a/charts/motive-cache/values.yaml b/charts/motive-cache/values.yaml index 56dd1cb..536b76b 100644 --- a/charts/motive-cache/values.yaml +++ b/charts/motive-cache/values.yaml @@ -3,18 +3,15 @@ # Declare variables to be passed into your templates. - # -- -------------- # Global # -- -------------- - nameOverride: "" fullnameOverride: "" - # -- -------------- # Varnish Cluster # -- -------------- @@ -54,10 +51,10 @@ backend: onlyReady: false # -- The port of the backend pods being cached by Varnish. Can be port name or port number. - port: "backend-port" + port: "" # -- The selector used to identify the backend Pods. - selector: {} + selector: # -- Controls Varnish backend topology aware routing which can assign weights to backends according to their geographical location. zoneBalancing: @@ -89,7 +86,7 @@ monitoring: # -- The Prometheus ServiceMonitor that is preconfigured to monitors the operator pods. prometheusServiceMonitor: # -- Enable or disable ServiceMontitor installation. - enabled: true + enabled: false # -- ServiceMonitor labels that will be used by Prometheus instance to discover this ServiceMonitor. labels: {} # -- The namespace it should be installed to. Default to the namespace VarnishCluster is installed to @@ -176,14 +173,16 @@ varnish: # -- An object that defines the VCL ConfigMap configuration vcl: # -- Name of the ConfigMap containing the VCL configuration files - configMapName: "tmp" + configMapName: "" # -- The name of the main VCL file - entrypointFileName: "tmp" + entrypointFileName: "" # -- -------------- # Ingress # -- -------------- + + ingress: internal: enabled: false