Skip to content

Commit

Permalink
chore(deploy): add service to expose Prometheus metrics (aquasecurity…
Browse files Browse the repository at this point in the history
…#796)

Signed-off-by: Daniel Pacak <pacak.daniel@gmail.com>
  • Loading branch information
danielpacak authored Nov 6, 2021
1 parent 564ac13 commit 612949f
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 18 deletions.
20 changes: 20 additions & 0 deletions deploy/helm/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,23 @@
---
apiVersion: v1
kind: Service
metadata:
name: {{ include "starboard-operator.fullname" . }}
labels:
{{- include "starboard-operator.labels" . | nindent 4 }}
{{- with .Values.service.annotations }}
annotations:
{{- . | toYaml | nindent 4 }}
{{- end }}
spec:
type: {{ .Values.service.type }}
ports:
- port: {{ .Values.service.metricsPort }}
targetPort: metrics
name: metrics
selector:
{{- include "starboard-operator.selectorLabels" . | nindent 4 }}
---
apiVersion: apps/v1
kind: Deployment
metadata:
Expand Down
18 changes: 0 additions & 18 deletions deploy/helm/templates/service.yaml

This file was deleted.

17 changes: 17 additions & 0 deletions deploy/static/04-starboard-operator.deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,21 @@
---
apiVersion: v1
kind: Service
metadata:
name: starboard-operator
namespace: starboard-system
annotations:
prometheus.io/path: /metrics
prometheus.io/scrape: "true"
spec:
type: ClusterIP
ports:
- port: 80
targetPort: metrics
name: metrics
selector:
app: starboard-operator
---
apiVersion: apps/v1
kind: Deployment
metadata:
Expand Down

0 comments on commit 612949f

Please sign in to comment.