apiVersion: extensions/v1beta1 kind: Deployment metadata: name: nginx-ingress namespace: nginx-ingress spec: replicas: 3 selector: matchLabels: app: nginx-ingress template: metadata: labels: app: nginx-ingress annotations: prometheus.io/scrape: "true" prometheus.io/port: "9113" spec: serviceAccountName: nginx-ingress priorityClassName: production-priority containers: - image: nginx/nginx-ingress:edge name: nginx-ingress ports: - name: http containerPort: 80 - name: https containerPort: 443 - name: beacon-relay containerPort: 20000 env: - name: POD_NAMESPACE valueFrom: fieldRef: fieldPath: metadata.namespace - name: POD_NAME valueFrom: fieldRef: fieldPath: metadata.name args: - -nginx-configmaps=$(POD_NAMESPACE)/nginx-config - -default-server-tls-secret=$(POD_NAMESPACE)/default-server-secret #- -v=3 # Enables extensive logging. Useful for troubleshooting. - -nginx-status - -nginx-status-port=8080 - -report-ingress-status - -external-service=nginx-ingress - -enable-leader-election - image: nginx/nginx-prometheus-exporter:0.1.0 name: nginx-prometheus-exporter ports: - name: prometheus containerPort: 9113 args: - -web.listen-address - :9113 - nginx.scrape-uri - http://127.0.0.1:8080/stub_status