apiVersion: couchbase.com/v2
kind: CouchbaseCluster
metadata:
  name: cb-example-perf
spec:
  antiAffinity: true
  buckets:
    managed: true
  cluster:
    autoFailoverMaxCount: 3
    autoFailoverOnDataDiskIssues: true
    autoFailoverOnDataDiskIssuesTimePeriod: 120s
    autoFailoverServerGroup: false
    autoFailoverTimeout: 120s
    dataServiceMemoryQuota: 256Mi
    indexServiceMemoryQuota: 256Mi
    indexStorageSetting: memory_optimized
  image: ghcr.io/cb-vanilla/server:7.2.4-7070
  monitoring:
    prometheus:
      enabled: true
      image: ghcr.io/cb-vanilla/exporter:1.0.11-100
      refreshRate: 60
  networking:
    cloudNativeGateway:
      image: ghcr.io/cb-vanilla/cloud-native-gateway:latest
    exposeAdminConsole: true
    exposedFeatures:
    - client
  security:
    adminSecret: cb-example-auth
    rbac:
      managed: true
      selector:
        matchLabels:
          cluster: cb-example-perf
  securityContext:
    fsGroup: 2000
    runAsGroup: 3000
    runAsUser: 1000
  servers:
  - name: data
    pod:
      metadata:
        annotations:
          sidecar.istio.io/inject: 'true'
      spec:
        imagePullSecrets:
        - name: regcred
        nodeSelector:
          NodeRoles: couchbase1
          kv_enabled: 'true'
    services:
    - data
    size: 3
    volumeMounts:
      default: couchbase_kv
  volumeClaimTemplates:
  - metadata:
      name: couchbase_kv
    spec:
      resources:
        requests:
          storage: 1000Gi
      storageClassName: perf-sc
