ci: collect memcached metrics (#7410)
* ci: collect memcached metrics * ci: use nobody/nobody for metrics container
This commit is contained in:
parent
dd46a8af6f
commit
3a4939cc0b
|
@ -16,6 +16,21 @@ spec:
|
|||
securityContext:
|
||||
runAsNonRoot: true
|
||||
containers:
|
||||
- image: "quay.io/prometheus/memcached-exporter:v0.14.3"
|
||||
imagePullPolicy: IfNotPresent
|
||||
name: memcached-exporter
|
||||
ports:
|
||||
- name: metrics
|
||||
containerPort: 9150
|
||||
protocol: TCP
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
capabilities:
|
||||
drop:
|
||||
- ALL
|
||||
readOnlyRootFilesystem: true
|
||||
runAsUser: 65534 # nobody
|
||||
runAsGroup: 65534 # nobody
|
||||
- image: "memcached:1.6-alpine"
|
||||
imagePullPolicy: IfNotPresent
|
||||
args: ["-m", "1024"]
|
||||
|
@ -41,6 +56,8 @@ apiVersion: v1
|
|||
kind: Service
|
||||
metadata:
|
||||
name: memcached
|
||||
annotations:
|
||||
k8s.grafana.com/scrape: "yes"
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
|
@ -48,5 +65,9 @@ spec:
|
|||
targetPort: memcached
|
||||
protocol: TCP
|
||||
name: memcached
|
||||
- port: 9150
|
||||
targetPort: metrics
|
||||
protocol: TCP
|
||||
name: metrics
|
||||
selector:
|
||||
app: memcached
|
||||
|
|
Loading…
Reference in a new issue