Add prometheus annotations to spec in ingress

Added annotations from metadata to spec.template.metadata. Without it, pod does not get any annotations, and Prometheus didn't see it
This commit is contained in:
gorazio 2018-03-20 08:47:36 +03:00 committed by GitHub
parent 8b6a6a5a28
commit aa30fa8009
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -20,6 +20,9 @@ spec:
labels:
k8s-app: ingress-nginx
version: v{{ ingress_nginx_controller_image_tag }}
annotations:
prometheus.io/port: '10254'
prometheus.io/scrape: 'true'
spec:
containers:
- name: ingress-nginx-controller