apiVersion: helm.toolkit.fluxcd.io/v2beta2
kind: HelmRelease
metadata:
  name: valuesfrom
spec:
  interval: 5m
  chart:
    spec:
      chart: podinfo
      version: '>=6.0.0 <7.0.0'
      sourceRef:
        kind: HelmRepository
        name: podinfo
      interval: 10m
  valuesFrom:
    - kind: ConfigMap
      name: valuesfrom-config
      valuesKey: resources.limits
    - kind: ConfigMap
      name: valuesfrom-config
      valuesKey: resources.requests
    - kind: ConfigMap
      name: valuesfrom-config
      valuesKey: resources.limits.cpu
      targetPath: resources.limits.cpu
    - kind: ConfigMap
      name: valuesfrom-config
      valuesKey: list.example
      targetPath: list.example
    - kind: ConfigMap
      name: valuesfrom-config
      valuesKey: list.example.overwrite
      targetPath: list.example[2]
    - kind: ConfigMap
      name: valuesfrom-config
      valuesKey: podAnnotation.example.value
      targetPath: podAnnotations.some\.k8s\.annotation\/env
    - kind: Secret
      name: valuesfrom-secret
  values:
    replicaCount: 2
