diff --git a/files/templates/scrapeconfigs/additional-scrape-configs.template.yaml b/files/templates/scrapeconfigs/additional-scrape-configs.template.yaml index 5b07eae5e..738328fc0 100644 --- a/files/templates/scrapeconfigs/additional-scrape-configs.template.yaml +++ b/files/templates/scrapeconfigs/additional-scrape-configs.template.yaml @@ -4,7 +4,7 @@ scheme: https kubernetes_sd_configs: - role: endpoints -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__meta_kubernetes_service_label_component] @@ -25,7 +25,7 @@ scheme: https kubernetes_sd_configs: - role: node -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig" . | indent 2 ]] relabel_configs: - target_label: __address__ @@ -55,7 +55,7 @@ namespaces: names: - giantswarm -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__meta_kubernetes_service_label_app_kubernetes_io_name] @@ -73,7 +73,7 @@ scheme: https kubernetes_sd_configs: - role: node -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - target_label: app @@ -103,7 +103,7 @@ scheme: https kubernetes_sd_configs: - role: node -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -144,7 +144,7 @@ scheme: https kubernetes_sd_configs: - role: pod -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -169,24 +169,24 @@ honor_labels: true scheme: https kubernetes_sd_configs: - [[ if .CAPIManagementCluster ]] + [[- if .CAPIManagementCluster ]] - role: pod namespaces: names: - kube-system - [[ else ]] + [[- else ]] - role: node - [[ end ]] -[[ if ne .ClusterType "management_cluster" ]] + [[- end ]] +[[- if ne .ClusterType "management_cluster" ]] api_server: https://[[ .APIServerURL ]] tls_config: ca_file: /etc/prometheus/secrets/[[ .SecretName ]]/ca cert_file: /etc/prometheus/secrets/[[ .SecretName ]]/crt key_file: /etc/prometheus/secrets/[[ .SecretName ]]/key insecure_skip_verify: false -[[ else ]] +[[- else ]] bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token -[[ end ]] +[[- end ]] tls_config: ca_file: /etc/prometheus/secrets/[[ .EtcdSecretName ]]/ca cert_file: /etc/prometheus/secrets/[[ .EtcdSecretName ]]/crt @@ -215,7 +215,7 @@ target_label: __address__ replacement: ${1}:2379 action: replace -[[ if eq .ClusterType "management_cluster" ]] +[[- if eq .ClusterType "management_cluster" ]] # if the 'ip' label is present, use the value - source_labels: [__meta_kubernetes_node_label_ip] regex: (.+) @@ -250,7 +250,7 @@ namespaces: names: - kube-system -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -302,7 +302,7 @@ namespaces: names: - kube-system -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -353,7 +353,7 @@ namespaces: names: - kube-system -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -387,7 +387,7 @@ namespaces: names: - kube-system -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -422,12 +422,12 @@ - role: endpoints namespaces: names: -[[ if eq .ClusterType "management_cluster" ]] +[[- if eq .ClusterType "management_cluster" ]] - monitoring -[[ else ]] +[[- else ]] - kube-system -[[ end ]] -[[ include "_apiserver" . ]] +[[- end ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__address__] @@ -455,7 +455,7 @@ scheme: https kubernetes_sd_configs: - role: pod -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - target_label: __address__ @@ -486,7 +486,7 @@ scheme: https kubernetes_sd_configs: - role: endpoints -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - source_labels: [__meta_kubernetes_service_annotationpresent_giantswarm_io_monitoring, __meta_kubernetes_service_labelpresent_giantswarm_io_monitoring] @@ -644,7 +644,7 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment -[[ if eq .ClusterType "management_cluster" ]] +[[- if eq .ClusterType "management_cluster" ]] # cert-operator (missing label) (versionned so it needs to be kept) - job_name: [[ .ClusterID ]]-prometheus/cert-operator-[[ .ClusterID ]]/0 honor_labels: true @@ -686,7 +686,7 @@ action: drop [[ include "_common" . | indent 2 ]] [[ include "_labelingschema" . | indent 2 ]] -[[ if .Bastions ]] +[[- if .Bastions ]] # bastion exporters - job_name: [[ .ClusterID ]]-prometheus/bastions-[[ .ClusterID ]]/0 honor_labels: true @@ -701,12 +701,12 @@ role: bastion relabel_configs: [[ include "_labelingschema" . | indent 2 ]] -[[ end ]] +[[- end ]] [[- if .AdditionalScrapeConfigs ]] # installation-specific configs from config repo [[ .AdditionalScrapeConfigs ]] [[- end ]] -[[ if eq .Provider "kvm" ]] +[[- if eq .Provider "kvm" ]] # flannel-operator (missing label) - job_name: [[ .ClusterID ]]-prometheus/flannel-operator-[[ .ClusterID ]]/0 honor_labels: true @@ -794,8 +794,8 @@ app: mayu relabel_configs: [[ include "_labelingschema" . | indent 2 ]] -[[ end ]] -[[ if not .CAPIManagementCluster ]] +[[- end ]] +[[- if not .CAPIManagementCluster ]] - job_name: [[ .ClusterID ]]-prometheus/vault-[[ .ClusterID ]]/0 honor_labels: true scheme: http @@ -814,7 +814,7 @@ app: vault-etcd-backups-exporter relabel_configs: [[ include "_labelingschema" . | indent 2 ]] -[[ end ]] +[[- end ]] # nginx-ingress-controller - job_name: [[ .ClusterID ]]-prometheus/nginx-ingress-controller-[[ .ClusterID ]]/0 honor_labels: true @@ -824,7 +824,7 @@ namespaces: names: - kube-system -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig" . | indent 2 ]] relabel_configs: - source_labels: [__meta_kubernetes_service_annotationpresent_giantswarm_io_monitoring, __meta_kubernetes_service_labelpresent_giantswarm_io_monitoring] @@ -853,7 +853,7 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop -[[ end ]] +[[- end ]] # prometheus - job_name: [[ .ClusterID ]]-prometheus/prometheus-[[ .ClusterID ]]/0 honor_labels: true @@ -875,7 +875,7 @@ namespaces: names: - kube-system -[[ include "_apiserver" . ]] +[[- include "_apiserver" . ]] [[ include "_tlsconfig_skip" . | indent 2 ]] relabel_configs: - replacement: http @@ -892,4 +892,4 @@ replacement: $1 [[ include "_common" . | indent 2 ]] [[ include "_labelingschema" . | indent 2 ]] -[[ end ]] +[[- end ]] diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-1-awsconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-1-awsconfig.golden index a7e3bea21..8c7452b83 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-1-awsconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-1-awsconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -461,7 +450,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -547,7 +535,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -624,7 +611,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -702,10 +688,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -776,7 +759,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -836,7 +818,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -1018,7 +999,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: alice-prometheus/prometheus-alice/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-2-azureconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-2-azureconfig.golden index ab61c3fcd..b26fe847c 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-2-azureconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-2-azureconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -452,7 +441,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -530,10 +518,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -604,7 +589,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -664,7 +648,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -846,7 +829,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: foo-prometheus/prometheus-foo/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-3-kvmconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-3-kvmconfig.golden index 6112aae5f..74f60a83d 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-3-kvmconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-3-kvmconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -461,7 +450,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -547,7 +535,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -624,7 +611,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -702,10 +688,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -776,7 +759,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -836,7 +818,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -1018,7 +999,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: bar-prometheus/prometheus-bar/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-4-control-plane.golden b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-4-control-plane.golden index 4f83269af..29637acdd 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-4-control-plane.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-4-control-plane.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -48,7 +47,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -101,7 +99,6 @@ namespaces: names: - giantswarm - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -154,7 +151,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -209,7 +205,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -268,7 +263,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -329,12 +323,8 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - tls_config: ca_file: /etc/prometheus/secrets/etcd-certificates/ca cert_file: /etc/prometheus/secrets/etcd-certificates/crt @@ -350,7 +340,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - # if the 'ip' label is present, use the value - source_labels: [__meta_kubernetes_node_label_ip] regex: (.+) @@ -397,7 +386,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -476,7 +464,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -555,7 +542,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -625,7 +611,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -696,10 +681,7 @@ - role: endpoints namespaces: names: - - monitoring - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -763,7 +745,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -816,7 +797,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -991,7 +971,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # cert-operator (missing label) (versionned so it needs to be kept) - job_name: kubernetes-prometheus/cert-operator-kubernetes/0 honor_labels: true @@ -1067,9 +1046,6 @@ # Add customer label. - target_label: customer replacement: pmo - - - - job_name: kubernetes-prometheus/vault-kubernetes/0 honor_labels: true scheme: http @@ -1108,7 +1084,6 @@ # Add customer label. - target_label: customer replacement: pmo - # nginx-ingress-controller - job_name: kubernetes-prometheus/nginx-ingress-controller-kubernetes/0 honor_labels: true @@ -1118,7 +1093,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1172,7 +1146,6 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop - # prometheus - job_name: kubernetes-prometheus/prometheus-kubernetes/0 honor_labels: true @@ -1213,7 +1186,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1267,4 +1239,3 @@ # Add customer label. - target_label: customer replacement: pmo - diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-5-cluster-api-v1alpha3.golden b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-5-cluster-api-v1alpha3.golden index 28f78e1ee..509a2a9e1 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-5-cluster-api-v1alpha3.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/aws/case-5-cluster-api-v1alpha3.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -452,7 +441,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -530,10 +518,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -604,7 +589,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -664,7 +648,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -846,7 +829,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: baz-prometheus/prometheus-baz/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-1-awsconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-1-awsconfig.golden index 7b2557b44..186a3b059 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-1-awsconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-1-awsconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -461,7 +450,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -547,7 +535,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -624,7 +611,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -702,10 +688,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -776,7 +759,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -836,7 +818,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -1018,7 +999,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: alice-prometheus/prometheus-alice/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-2-azureconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-2-azureconfig.golden index 8ab02592d..b0ce514a1 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-2-azureconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-2-azureconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -452,7 +441,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -530,10 +518,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -604,7 +589,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -664,7 +648,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -846,7 +829,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: foo-prometheus/prometheus-foo/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-3-kvmconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-3-kvmconfig.golden index a40baabe1..6c9a7d6d5 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-3-kvmconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-3-kvmconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -461,7 +450,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -547,7 +535,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -624,7 +611,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -702,10 +688,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -776,7 +759,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -836,7 +818,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -1018,7 +999,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: bar-prometheus/prometheus-bar/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-4-control-plane.golden b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-4-control-plane.golden index a9381a774..f477b7b49 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-4-control-plane.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-4-control-plane.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -48,7 +47,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -101,7 +99,6 @@ namespaces: names: - giantswarm - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -154,7 +151,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -209,7 +205,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -268,7 +263,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -329,12 +323,8 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - tls_config: ca_file: /etc/prometheus/secrets/etcd-certificates/ca cert_file: /etc/prometheus/secrets/etcd-certificates/crt @@ -350,7 +340,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - # if the 'ip' label is present, use the value - source_labels: [__meta_kubernetes_node_label_ip] regex: (.+) @@ -397,7 +386,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -476,7 +464,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -555,7 +542,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -625,7 +611,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -696,10 +681,7 @@ - role: endpoints namespaces: names: - - monitoring - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -763,7 +745,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -816,7 +797,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -991,7 +971,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # cert-operator (missing label) (versionned so it needs to be kept) - job_name: kubernetes-prometheus/cert-operator-kubernetes/0 honor_labels: true @@ -1067,9 +1046,6 @@ # Add customer label. - target_label: customer replacement: pmo - - - - job_name: kubernetes-prometheus/vault-kubernetes/0 honor_labels: true scheme: http @@ -1108,7 +1084,6 @@ # Add customer label. - target_label: customer replacement: pmo - # nginx-ingress-controller - job_name: kubernetes-prometheus/nginx-ingress-controller-kubernetes/0 honor_labels: true @@ -1118,7 +1093,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1172,7 +1146,6 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop - # prometheus - job_name: kubernetes-prometheus/prometheus-kubernetes/0 honor_labels: true @@ -1213,7 +1186,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1267,4 +1239,3 @@ # Add customer label. - target_label: customer replacement: pmo - diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-5-cluster-api-v1alpha3.golden b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-5-cluster-api-v1alpha3.golden index 10aa6bc46..9315eebae 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-5-cluster-api-v1alpha3.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/azure/case-5-cluster-api-v1alpha3.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -452,7 +441,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -530,10 +518,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -604,7 +589,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -664,7 +648,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -846,7 +829,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: baz-prometheus/prometheus-baz/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-1-awsconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-1-awsconfig.golden index bf05d79ea..6c0047d35 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-1-awsconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-1-awsconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: alice-prometheus/prometheus-alice/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-2-azureconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-2-azureconfig.golden index 37f963195..aa8b51965 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-2-azureconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-2-azureconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: foo-prometheus/prometheus-foo/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-3-kvmconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-3-kvmconfig.golden index 11de58f87..427b90986 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-3-kvmconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-3-kvmconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: bar-prometheus/prometheus-bar/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-4-control-plane.golden b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-4-control-plane.golden index 055642c8c..284df7e9f 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-4-control-plane.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-4-control-plane.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -51,7 +50,6 @@ namespaces: names: - giantswarm - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -104,7 +102,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -159,7 +156,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -218,7 +214,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -279,15 +274,11 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - tls_config: ca_file: /etc/prometheus/secrets/etcd-certificates/ca cert_file: /etc/prometheus/secrets/etcd-certificates/crt @@ -345,7 +336,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -424,7 +414,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -503,7 +492,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -573,7 +561,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -644,10 +631,7 @@ - role: endpoints namespaces: names: - - monitoring - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -711,7 +695,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -764,7 +747,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -939,7 +921,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # cert-operator (missing label) (versionned so it needs to be kept) - job_name: kubernetes-prometheus/cert-operator-kubernetes/0 honor_labels: true @@ -1015,7 +996,6 @@ # Add customer label. - target_label: customer replacement: pmo - # installation-specific configs from config repo - job_name: test1 static_configs: @@ -1031,8 +1011,6 @@ relabel_configs: - source_labels: [__address__] target_label: __param_target - - # nginx-ingress-controller - job_name: kubernetes-prometheus/nginx-ingress-controller-kubernetes/0 honor_labels: true @@ -1042,7 +1020,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1096,7 +1073,6 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop - # prometheus - job_name: kubernetes-prometheus/prometheus-kubernetes/0 honor_labels: true @@ -1137,7 +1113,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1191,4 +1166,3 @@ # Add customer label. - target_label: customer replacement: pmo - diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-5-cluster-api-v1alpha3.golden b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-5-cluster-api-v1alpha3.golden index a02c9dca6..b516610b4 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-5-cluster-api-v1alpha3.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/capa/case-5-cluster-api-v1alpha3.golden @@ -5,7 +5,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -67,7 +66,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -133,7 +131,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -201,20 +198,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -272,7 +265,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -349,7 +341,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -427,10 +418,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -500,7 +488,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -685,7 +672,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: baz-prometheus/prometheus-baz/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-1-awsconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-1-awsconfig.golden index bec2c5b6d..3429d9262 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-1-awsconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-1-awsconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: alice-prometheus/prometheus-alice/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-2-azureconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-2-azureconfig.golden index 91add138d..9dce1dc64 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-2-azureconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-2-azureconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: foo-prometheus/prometheus-foo/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-3-kvmconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-3-kvmconfig.golden index cbdfd371f..59a1708f7 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-3-kvmconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-3-kvmconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: bar-prometheus/prometheus-bar/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-4-control-plane.golden b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-4-control-plane.golden index 54e7495bd..951a9b6ed 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-4-control-plane.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-4-control-plane.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -51,7 +50,6 @@ namespaces: names: - giantswarm - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -104,7 +102,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -159,7 +156,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -218,7 +214,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -279,15 +274,11 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - tls_config: ca_file: /etc/prometheus/secrets/etcd-certificates/ca cert_file: /etc/prometheus/secrets/etcd-certificates/crt @@ -345,7 +336,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -424,7 +414,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -503,7 +492,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -573,7 +561,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -644,10 +631,7 @@ - role: endpoints namespaces: names: - - monitoring - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -711,7 +695,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -764,7 +747,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -939,7 +921,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # cert-operator (missing label) (versionned so it needs to be kept) - job_name: kubernetes-prometheus/cert-operator-kubernetes/0 honor_labels: true @@ -1015,7 +996,6 @@ # Add customer label. - target_label: customer replacement: pmo - # installation-specific configs from config repo - job_name: test1 static_configs: @@ -1031,8 +1011,6 @@ relabel_configs: - source_labels: [__address__] target_label: __param_target - - # nginx-ingress-controller - job_name: kubernetes-prometheus/nginx-ingress-controller-kubernetes/0 honor_labels: true @@ -1042,7 +1020,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1096,7 +1073,6 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop - # prometheus - job_name: kubernetes-prometheus/prometheus-kubernetes/0 honor_labels: true @@ -1137,7 +1113,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1191,4 +1166,3 @@ # Add customer label. - target_label: customer replacement: pmo - diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-5-cluster-api-v1alpha3.golden b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-5-cluster-api-v1alpha3.golden index 0f03ea72d..a44c08184 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-5-cluster-api-v1alpha3.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/gcp/case-5-cluster-api-v1alpha3.golden @@ -5,7 +5,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -67,7 +66,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -133,7 +131,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -201,20 +198,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -272,7 +265,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -349,7 +341,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -427,10 +418,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -500,7 +488,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -685,7 +672,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: baz-prometheus/prometheus-baz/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-1-awsconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-1-awsconfig.golden index 01dc3fc19..7054c50e1 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-1-awsconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-1-awsconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -461,7 +450,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -547,7 +535,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -624,7 +611,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -702,10 +688,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -776,7 +759,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -836,7 +818,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -1018,7 +999,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: alice-prometheus/prometheus-alice/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-2-azureconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-2-azureconfig.golden index f8efcac82..87c381eb3 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-2-azureconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-2-azureconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -452,7 +441,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -530,10 +518,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -604,7 +589,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -664,7 +648,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -846,7 +829,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: foo-prometheus/prometheus-foo/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-3-kvmconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-3-kvmconfig.golden index 789b36adc..5a9d47ee8 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-3-kvmconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-3-kvmconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -461,7 +450,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -547,7 +535,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -624,7 +611,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -702,10 +688,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -776,7 +759,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -836,7 +818,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -1018,7 +999,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: bar-prometheus/prometheus-bar/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-4-control-plane.golden b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-4-control-plane.golden index 20d16ec39..997ba028c 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-4-control-plane.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-4-control-plane.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -48,7 +47,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -101,7 +99,6 @@ namespaces: names: - giantswarm - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -154,7 +151,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -209,7 +205,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -268,7 +263,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -329,12 +323,8 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - tls_config: ca_file: /etc/prometheus/secrets/etcd-certificates/ca cert_file: /etc/prometheus/secrets/etcd-certificates/crt @@ -350,7 +340,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - # if the 'ip' label is present, use the value - source_labels: [__meta_kubernetes_node_label_ip] regex: (.+) @@ -397,7 +386,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -476,7 +464,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -555,7 +542,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -625,7 +611,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -696,10 +681,7 @@ - role: endpoints namespaces: names: - - monitoring - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -763,7 +745,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -816,7 +797,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -991,7 +971,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # cert-operator (missing label) (versionned so it needs to be kept) - job_name: kubernetes-prometheus/cert-operator-kubernetes/0 honor_labels: true @@ -1067,7 +1046,6 @@ # Add customer label. - target_label: customer replacement: pmo - # installation-specific configs from config repo - job_name: test1 static_configs: @@ -1083,7 +1061,6 @@ relabel_configs: - source_labels: [__address__] target_label: __param_target - # flannel-operator (missing label) - job_name: kubernetes-prometheus/flannel-operator-kubernetes/0 honor_labels: true @@ -1293,8 +1270,6 @@ # Add customer label. - target_label: customer replacement: pmo - - - job_name: kubernetes-prometheus/vault-kubernetes/0 honor_labels: true scheme: http @@ -1333,7 +1308,6 @@ # Add customer label. - target_label: customer replacement: pmo - # nginx-ingress-controller - job_name: kubernetes-prometheus/nginx-ingress-controller-kubernetes/0 honor_labels: true @@ -1343,7 +1317,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1397,7 +1370,6 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop - # prometheus - job_name: kubernetes-prometheus/prometheus-kubernetes/0 honor_labels: true @@ -1438,7 +1410,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1492,4 +1463,3 @@ # Add customer label. - target_label: customer replacement: pmo - diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-5-cluster-api-v1alpha3.golden b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-5-cluster-api-v1alpha3.golden index ad794eaa5..8258f79cb 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-5-cluster-api-v1alpha3.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/kvm/case-5-cluster-api-v1alpha3.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -112,7 +110,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -174,7 +171,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -240,7 +236,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -308,17 +303,13 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: node - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -334,7 +325,6 @@ target_label: __address__ replacement: ${1}:2379 action: replace - - target_label: app replacement: etcd - source_labels: [__address__] @@ -375,7 +365,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -452,7 +441,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -530,10 +518,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -604,7 +589,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -664,7 +648,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -846,7 +829,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: baz-prometheus/prometheus-baz/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-1-awsconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-1-awsconfig.golden index 85fdc16e0..7df53c02c 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-1-awsconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-1-awsconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.alice:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: alice-prometheus/prometheus-alice/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-2-azureconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-2-azureconfig.golden index 0ec5192b5..44e56671d 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-2-azureconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-2-azureconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.foo:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: foo-prometheus/prometheus-foo/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-3-kvmconfig.golden b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-3-kvmconfig.golden index f323a77a0..a7e92d0ed 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-3-kvmconfig.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-3-kvmconfig.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -55,7 +54,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -117,7 +115,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -183,7 +180,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -251,20 +247,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -322,7 +314,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -408,7 +399,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -494,7 +484,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -571,7 +560,6 @@ namespaces: names: - kube-system - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -649,10 +637,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -723,7 +708,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -783,7 +767,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.bar:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -965,7 +948,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: bar-prometheus/prometheus-bar/0 honor_labels: true diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-4-control-plane.golden b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-4-control-plane.golden index 9abf1d15d..c8a370e3a 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-4-control-plane.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-4-control-plane.golden @@ -4,7 +4,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -51,7 +50,6 @@ namespaces: names: - giantswarm - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -104,7 +102,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -159,7 +156,6 @@ scheme: https kubernetes_sd_configs: - role: node - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -218,7 +214,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -279,15 +274,11 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - tls_config: ca_file: /etc/prometheus/secrets/etcd-certificates/ca cert_file: /etc/prometheus/secrets/etcd-certificates/crt @@ -345,7 +336,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -424,7 +414,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -503,7 +492,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -573,7 +561,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -644,10 +631,7 @@ - role: endpoints namespaces: names: - - monitoring - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -711,7 +695,6 @@ scheme: https kubernetes_sd_configs: - role: pod - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -764,7 +747,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -939,7 +921,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # cert-operator (missing label) (versionned so it needs to be kept) - job_name: kubernetes-prometheus/cert-operator-kubernetes/0 honor_labels: true @@ -1015,7 +996,6 @@ # Add customer label. - target_label: customer replacement: pmo - # installation-specific configs from config repo - job_name: test1 static_configs: @@ -1031,8 +1011,6 @@ relabel_configs: - source_labels: [__address__] target_label: __param_target - - # nginx-ingress-controller - job_name: kubernetes-prometheus/nginx-ingress-controller-kubernetes/0 honor_labels: true @@ -1042,7 +1020,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1096,7 +1073,6 @@ - source_labels: [__name__] regex: nginx_ingress_controller_(bytes_sent_bucket|request_size_bucket|response_duration_seconds_bucket|response_size_bucket|request_duration_seconds_count|connect_duration_seconds_bucket|header_duration_seconds_bucket|bytes_sent_count|request_duration_seconds_sum|bytes_sent_sum|request_size_count|response_size_count|response_duration_seconds_sum|response_duration_seconds_count|ingress_upstream_latency_seconds|ingress_upstream_latency_seconds_sum|ingress_upstream_latency_seconds_count) action: drop - # prometheus - job_name: kubernetes-prometheus/prometheus-kubernetes/0 honor_labels: true @@ -1137,7 +1113,6 @@ namespaces: names: - kube-system - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt @@ -1191,4 +1166,3 @@ # Add customer label. - target_label: customer replacement: pmo - diff --git a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-5-cluster-api-v1alpha3.golden b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-5-cluster-api-v1alpha3.golden index c6873b0bf..d30812f24 100644 --- a/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-5-cluster-api-v1alpha3.golden +++ b/service/controller/resource/monitoring/scrapeconfigs/test/openstack/case-5-cluster-api-v1alpha3.golden @@ -5,7 +5,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -67,7 +66,6 @@ scheme: https kubernetes_sd_configs: - role: node - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -133,7 +131,6 @@ scheme: https kubernetes_sd_configs: - role: pod - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -201,20 +198,16 @@ honor_labels: true scheme: https kubernetes_sd_configs: - - role: pod namespaces: names: - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt key_file: /etc/prometheus/secrets/cluster-certificates/key insecure_skip_verify: false - tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca cert_file: /etc/prometheus/secrets/cluster-certificates/crt @@ -272,7 +265,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -349,7 +341,6 @@ namespaces: names: - kube-system - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -427,10 +418,7 @@ - role: endpoints namespaces: names: - - kube-system - - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -500,7 +488,6 @@ scheme: https kubernetes_sd_configs: - role: endpoints - api_server: https://master.baz:443 tls_config: ca_file: /etc/prometheus/secrets/cluster-certificates/ca @@ -685,7 +672,6 @@ action: replace - action: labeldrop regex: label_giantswarm_io_machine_pool|label_giantswarm_io_machine_deployment - # prometheus - job_name: baz-prometheus/prometheus-baz/0 honor_labels: true