repositories:
- name: myrepo
  url: http://localhost:18084/

templates:
  base:
    valuesTemplate:
    - base: base
    labels:
      base: base
    chart: ../../charts/raw-0.1.0
  template1:
    values:
    - template1: template1
    valuesTemplate:
    - template1Label: "{{`{{ .Release.Labels.template1 }}`}}"
    labels:
      template1: template1
    inherit:
    - template: base
      except:
      - labels
  template2:
    values:
    - template2: template2
    valuesTemplate:
    - inheritedBaseLabel: "{{`{{ .Release.Labels.base }}`}}"
      template2Label: "{{`{{ .Release.Labels.template2 }}`}}"
    labels:
      template2: template2
    inherit:
    - template: base
      except:
      - valuesTemplate

releases:
- name: foo1
  inherit:
  - template: template1
  values:
  - templates:
    - |
      apiVersion: v1
      kind: ConfigMap
      metadata:
        name: {{`{{ .Release.Name }}`}}-1
        namespace: {{`{{ .Release.Namespace }}`}}
      data:
        {{` {{ (unset .Values "templates") | toYaml | nindent 2 }} `}}
- name: foo2
  inherit:
  - template: template2
  values:
  - templates:
    - |
      apiVersion: v1
      kind: ConfigMap
      metadata:
        name: {{`{{ .Release.Name }}`}}-1
        namespace: {{`{{ .Release.Namespace }}`}}
      data:
        {{` {{ (unset .Values "templates") | toYaml | nindent 2 }} `}}