-
Notifications
You must be signed in to change notification settings - Fork 0
/
mackerel.d.ts
113 lines (107 loc) · 2.33 KB
/
mackerel.d.ts
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
interface BlockDevice {
model?: string;
removable: string;
rev?: string;
size: string;
state?: string;
timeout?: string;
vendor?: string;
}
interface CPU {
cache_size?: string;
core_id?: string;
cores?: string;
family?: string;
mhz: string | number;
model: string | number;
model_name: string;
physical_id?: string;
stepping?: string;
vendor_id: string;
}
interface FileSystem {
fs_type?: string;
kb_available: number;
kb_size: number;
kb_used: number;
label?: string;
mount: string;
percent_used: string;
volume_name?: string;
}
interface Kernel {
machine: string;
name: string;
os: string;
platform_name: string;
platform_version: string;
release: string;
version: string;
}
interface Memory {
active?: string;
anon_pages?: string;
bounce?: string;
buffers?: string;
cached?: string;
commit_limit?: string;
committed_as?: string;
dirty?: string;
free: string;
inactive?: string;
mapped?: string;
nfs_unstable?: string;
page_tables?: string;
slab?: string;
slab_reclaimable?: string;
slab_unreclaim?: string;
swap_cached?: string;
swap_free?: string;
swap_total?: string;
total: string;
vmalloc_chunk?: string;
vmalloc_total?: string;
vmalloc_used?: string;
writeback?: string;
}
interface HostMeta {
'agent-revision': string;
'agent-version': string;
'agent-name': string;
block_device: {[key: string]: BlockDevice};
cpu: CPU[];
filesystem: {[key: string]: FileSystem};
kernel: Kernel;
memory: Memory;
cloud?: {
provider: 'gce';
metadata: {
hostname: string;
'instance-id': string;
'instance-type': string;
projectId: string;
zone: string;
};
}
}
interface Host {
name: string;
displayName: string | null;
customIdentifier: string;
meta: HostMeta;
size: string;
status: string; // working
memo: string;
isRetired: boolean;
id: string;
createdAt: number;
roles: {[key: string]: string[]};
interfaces: {
macAddress: string;
name: string;
ipv4Addresses: string[];
ipv6Addresses: string[];
ipAddress: string;
ipv6Address: string;
}[];
}