forked from DazWilkin/gcp-exporter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkubernetes.yaml
62 lines (62 loc) · 1.45 KB
/
kubernetes.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
apiVersion: v1
kind: List
metadata: {}
items:
- kind: Service
apiVersion: v1
metadata:
labels:
app: gcp-exporter
name: gcp-exporter
spec:
selector:
app: gcp-exporter
ports:
- name: metrics
port: 9402
targetPort: 9402
- kind: Deployment
apiVersion: apps/v1
metadata:
labels:
app: gcp-exporter
name: gcp-exporter
spec:
replicas: 1
selector:
matchLabels:
app: gcp-exporter
template:
metadata:
labels:
app: gcp-exporter
spec:
containers:
- name: gcp-exporter
image: ghcr.io/dazwilkin/gcp-exporter:d211a0377ad7c82c25ed44c0367ce92d47cea3f3
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /secrets/client_secrets.json
ports:
- name: metrics
containerPort: 9402
volumeMounts:
- name: secrets
mountPath: /secrets
restartPolicy: Always
volumes:
- name: secrets
secret:
secretName: gcp-exporter
- kind: ServiceMonitor
apiVersion: monitoring.coreos.com/v1
metadata:
name: gcp-exporter
labels:
app: gcp-exporter
spec:
selector:
matchLabels:
app: gcp-exporter
endpoints:
- port: metrics