apiVersion: v1
kind: ConfigMap
metadata:
  name: collector-config
  namespace: pks-system
data:
  collector.yaml: |
    clusterName: cluster1
    enableEvents: false
    enableDiscovery: true
    flushInterval: 30s

    # sample configuration to filter events
    # events:
    #   filters:
    #     tagWhitelistSets:
    #     - kind:
    #       - "Pod"
    #       reason:
    #       - "Scheduled"
    #     - kind:
    #       - "DaemonSet"
    #       reason:
    #       - "SuccessfulCreate"
   
    sinks:
    - proxyAddress: wavefront-proxy.pks-system.svc.cluster.local:2878
      filters:
        # Filter out generated labels
        tagExclude:
        - 'label?controller?revision*'
        - 'label?pod?template*'
        - 'annotation_kubectl_kubernetes_io_last_applied_configuration'

    sources:
      kubernetes_source:
        url: 'https://kubernetes.default.svc'
        kubeletPort: 10250
        kubeletHttps: true
        useServiceAccount: true
        insecure: true
        prefix: 'pks.'

        filters:
          metricBlacklist:
          - 'kubernetes.sys_container.*'

      internal_stats_source:
        prefix: 'pks.'

      kubernetes_state_source:
        prefix: 'pks.'


