-
Notifications
You must be signed in to change notification settings - Fork 1
/
config-k8s.yaml
59 lines (59 loc) · 2.05 KB
/
config-k8s.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
resources:
- kind: v1/namespaces
selector:
query: .metadata.name | contains("kube-system")
port:
entity:
mappings:
- identifier: '"dot"'
title: '"dot"'
blueprint: '"cluster"'
- kind: v1/namespaces
selector:
query: .metadata.name | startswith("kube") | not
port:
entity:
mappings:
- identifier: .metadata.name + "-" + "dot"
title: .metadata.name
blueprint: '"namespace"'
properties:
creationTimestamp: .metadata.creationTimestamp
labels: .metadata.labels
relations:
Cluster: '"dot"'
- kind: v1/nodes
port:
entity:
mappings:
- identifier: (.metadata.name) | (split(".")|join("_")) + "-" + "dot"
title: .metadata.name + "-" + "dot"
icon: '"Node"'
blueprint: '"node"'
properties:
creationTimestamp: .metadata.creationTimestamp
totalCPU: .status.allocatable.cpu
totalMemory: .status.allocatable.memory
labels: .metadata.labels
kubeletVersion: .status.nodeInfo.kubeletVersion | split("-") | .[0]
ready: .status.conditions[] | select(.type == "Ready") | .status
relations:
Cluster: '"dot"'
- kind: v1/pods
selector:
query: .metadata.namespace | startswith("kube") | not
port:
entity:
mappings:
- identifier: .metadata.name + "-" + .metadata.namespace + "-" + "dot"
title: .metadata.name
icon: '"Microservices"'
blueprint: '"pod"'
properties:
startTime: .status.startTime
phase: .status.phase
labels: .metadata.labels
containers: (.spec.containers | map({image, resources})) + .status.containerStatuses | group_by(.image) | map(add)
conditions: .status.conditions
relations:
Node: (.spec.nodeName) | (split(".")|join("_")) + "-" + "dot"