-
Notifications
You must be signed in to change notification settings - Fork 1
/
deployment-exporter.yaml
74 lines (74 loc) · 1.41 KB
/
deployment-exporter.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: vm-exporter
namespace: alitke-migrate-vm-demo
spec:
selector:
matchLabels:
app: vm-exporter
replicas: 1
template:
metadata:
labels:
app: vm-exporter
spec:
containers:
- name: exporter
image: quay.io/alitke/vm-exporter
resources:
requests:
memory: 100Mi
cpu: 0.2
ports:
- name: http
containerPort: 8080
env:
- name: "PORT"
value: "8080"
- name: "DISK_FILE"
value: "/data/disk.img"
volumeMounts:
- mountPath: /data
name: vm-disk
volumes:
- name: vm-disk
persistentVolumeClaim:
claimName: vagabond
---
apiVersion: v1
kind: Service
metadata:
name: vm-exporter
namespace: alitke-migrate-vm-demo
spec:
ipFamilies:
- IPv4
ipFamilyPolicy: SingleStack
ports:
- port: 80
protocol: TCP
targetPort: 8080
name: http
selector:
app: vm-exporter
sessionAffinity: None
type: NodePort
---
apiVersion: route.openshift.io/v1
kind: Route
metadata:
annotations:
openshift.io/host.generated: "true"
name: vm-exporter
namespace: alitke-migrate-vm-demo
spec:
host: vm-exporter-alitke-migrate-vm-demo.apps.example.com
port:
targetPort: http
to:
kind: Service
name: vm-exporter
weight: 100
wildcardPolicy: None