Below you will find pages that utilize the taxonomy term “Prometheus Operator”
Patch Prometheus Operator `externalUrl`
I continue to learn “tricks” with Prometheus and (kube-prometheus ⊃ Prometheus Operator).
For too long, I’ve lived with Alertmanager alerts including “View in Alertmanager” and “Source” hyperlinks that don’t work because they defaulted incorrectly.
The solution when running either Prometheus or Alertmanager (same for both) is to use the flag:
--web.external-url="${EXTERNAL_URL}"
Conveniently, when running kube-prometheus, there are Prometheus and Alertmanager CRDs for configuring Prometheus and Alertmanager and these include the field:
externalUrl: "${EXTERNAL_URL}"
The question is: How to configure this value?
Ingress contains no valid backends
Using MicroK8s with the new observability addon which uses Helm to install kube-prometheus.
This results in various Resources including several Service’s:
kubectl get services \
--namespace=observability
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S)
alertmanager-operated ClusterIP None <none> 9093/TCP,9094/TCP,9094/UDP
kube-prom-stack-kube-prome-alertmanager ClusterIP 10.152.183.201 <none> 9093/TCP
kube-prom-stack-kube-prome-operator ClusterIP 10.152.183.44 <none> 443/TCP
kube-prom-stack-kube-prome-prometheus ClusterIP 10.152.183.206 <none> 9090/TCP
kube-prom-stack-kube-state-metrics ClusterIP 10.152.183.126 <none> 8080/TCP
prometheus-operated ClusterIP None <none> 9090/TCP
I’m using Tailscale Kubernetes Operator to expose MicroK8s services using Ingress to my tailnet.