-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathprometheus-deployment.yaml
41 lines (41 loc) · 1.08 KB
/
prometheus-deployment.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
kind: Deployment
apiVersion: apps/v1
metadata:
labels:
app: prometheus-server
name: prometheus-deployment
namespace: monitoring
spec:
replicas: 0
selector:
matchLabels:
app: prometheus-server
template:
metadata:
labels:
app: prometheus-server
spec:
volumes:
- name: prometheus-config-volume
configMap:
name: prometheus-server-conf
defaultMode: 420
- name: prometheus-storage-volume
persistentVolumeClaim:
claimName: prometheus-storage-volume
containers:
- name: prometheus
image: 'prom/prometheus:latest'
args:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus/'
ports:
- containerPort: 9090
protocol: TCP
resources: {}
volumeMounts:
- name: prometheus-config-volume
mountPath: /etc/prometheus/
- name: prometheus-storage-volume
mountPath: /prometheus/
restartPolicy: Always