prometheus-community / helm-charts

Prometheus community Helm charts
Apache License 2.0
5.09k stars 5.02k forks source link

[kube-prometheus-stack] Proper way to add scrapes for ECS cluster to Kube-Promethues-Stack config. #4208

Open dburrows-poloniex opened 9 months ago

dburrows-poloniex commented 9 months ago

I have deployed Kube-Promethues-Stack with Helm thru Terrafrom and its working. However, I have a number of items outside of the EKS cluster that need to be scraped. Where shoudl these job exist and in which yaml files and how shoudl it be best deployed. I need to scrape metrics from some ECS clusters and come EC2 instanaces. I woudl like to find an example where this has been done. Anyone have any exmaples of pathways to share? Any guidance woudl be greatly appreciated.

dburrows-poloniex commented 8 months ago

Redeployment of chart with terraform using a values.yaml file. Here is the segment of values.yaml.

prometheus: enabled: true annotations: {} serviceAccount: create: true name: "" annotations: {} enabled: false annotations: {} labels: {} loadBalancerIP: "" loadBalancerSourceRanges: [] portName: grpc port: 10901 targetPort: "grpc" httpPortName: http httpPort: 10902 targetHttpPort: "http" type: LoadBalancer nodePort: 30901 httpNodePort: 30902 service: annotations: {} labels: {} clusterIP: "" port: 9090 targetPort: 9090 externalIPs: [] nodePort: 30090 loadBalancerIP: "" loadBalancerSourceRanges: [] type: ClusterIP sessionAffinity: "" servicePerReplica: enabled: false annotations: {} port: 9090 targetPort: 9090 nodePort: 30091 loadBalancerSourceRanges: [] type: ClusterIP podDisruptionBudget: enabled: false minAvailable: 1 maxUnavailable: "" extraSecret: annotations: {} data: {} podSecurityPolicy: allowedCapabilities: [] allowedHostPaths: [] volumes: [] serviceMonitor: interval: "" selfMonitor: true scheme: "" tlsConfig: {} bearerTokenFile: metricRelabelings: [] relabelings: [] prometheusSpec: disableCompaction: false apiserverConfig: {} scrapeInterval: "" scrapeTimeout: "" evaluationInterval: "" listenLocal: false enableAdminAPI: false web: {} enableFeatures: [] image: repository: prometheus/prometheus tag: v2.28.1 sha: "" tolerations: [] topologySpreadConstraints: [] alertingEndpoints: [] externalLabels: {} replicaExternalLabelName: "" replicaExternalLabelNameClear: false prometheusExternalLabelName: "" prometheusExternalLabelNameClear: false externalUrl: "" nodeSelector: {} secrets: [] configMaps: [] query: {} ruleNamespaceSelector: {} ruleSelectorNilUsesHelmValues: true ruleSelector: {} serviceMonitorSelectorNilUsesHelmValues: true serviceMonitorSelector: {} serviceMonitorNamespaceSelector: {} podMonitorSelectorNilUsesHelmValues: true podMonitorSelector: {} podMonitorNamespaceSelector: {} probeSelectorNilUsesHelmValues: true probeSelector: {} probeNamespaceSelector: {} scrapeConfigSelectorNilUsesHelmValues: true scrapeConfigSelector: {} scrapeConfigNamespaceSelector: {} retention: 10d retentionSize: "" walCompression: false paused: false replicas: 1 shards: 1 logLevel: info logFormat: logfmt routePrefix: / podMetadata: {} podAntiAffinity: "" podAntiAffinityTopologyKey: kubernetes.io/hostname affinity: {} remoteRead: [] additionalRemoteRead: [] remoteWrite: [] additionalRemoteWrite: [] remoteWriteDashboards: true resources: {} storageSpec: {} volumes: [] volumeMounts: [] additionalScrapeConfigs: |-