github.com/1aal/kubeblocks@v0.0.0-20231107070852-e1c03e598921/deploy/helm/templates/addons/loki-addon.yaml (about)

     1  apiVersion: extensions.kubeblocks.io/v1alpha1
     2  kind: Addon
     3  metadata:
     4    name: {{ include "addon.loki.name" . }}
     5    labels:
     6      {{- include "kubeblocks.labels" . | nindent 4 }}
     7      "kubeblocks.io/provider": community
     8    {{- if .Values.keepAddons }}
     9    annotations:
    10      helm.sh/resource-policy: keep
    11    {{- end }}
    12  spec:
    13    description: Grafana Loki is a horizontally scalable, highly available, and multi-tenant log aggregation system, which inspired by Prometheus.
    14    type: Helm
    15  
    16    helm:
    17      {{- include "kubeblocks.addonChartLocationURL" ( dict "name" "loki" "version" "5.8.9" "values" .Values) | indent 4 }}
    18      {{- include "kubeblocks.addonChartsImage" . | indent 4 }}
    19  
    20      installOptions:
    21        {{- if hasPrefix "oci://" .Values.addonChartLocationBase }}
    22        version: 5.8.9
    23        {{- end }}
    24  
    25      installValues:
    26        configMapRefs:
    27          - name: {{ include "addon.loki.name" . }}-chart-kubeblocks-values
    28            key: values-kubeblocks-override.yaml
    29  
    30      valuesMapping:
    31        valueMap:
    32          replicaCount: singleBinary.replicas
    33          storageClass: singleBinary.persistence.storageClass
    34          persistentVolumeEnabled: singleBinary.persistence.enabled
    35  
    36        jsonMap:
    37          tolerations: global.tolerations
    38  
    39        resources:
    40          storage: singleBinary.persistence.size
    41  
    42    defaultInstallValues:
    43      - replicas: 1
    44        storageClass:
    45        resources:
    46          requests:
    47            storage: 8Gi
    48        {{- with .Values.tolerations }}
    49        tolerations: {{ toJson . | quote }}
    50        {{- end }}
    51      # for ACK, the smallest storage size is 20Gi, the format of GitVersion is v1.24.6-aliyun.1
    52      - selectors:
    53          - key: KubeGitVersion
    54            operator: Contains
    55            values:
    56              - aliyun
    57        replicas: 1
    58        resources:
    59          requests:
    60            storage: 20Gi
    61        {{- with .Values.tolerations }}
    62        tolerations: {{ toJson . | quote }}
    63        {{- end }}
    64      # for TKE, the smallest storage size is 10Gi, the format of GitVersion is v1.24.4-tke.5
    65      - selectors:
    66          - key: KubeGitVersion
    67            operator: Contains
    68            values:
    69              - tke
    70        replicas: 1
    71        resources:
    72          requests:
    73            storage: 10Gi
    74        {{- with .Values.tolerations }}
    75        tolerations: {{ toJson . | quote }}
    76        {{- end }}
    77  
    78    installable:
    79      autoInstall: {{ .Values.loki.enabled }}
    80  
    81