-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathtest-ok-string-greaselog.config
280 lines (276 loc) · 10.8 KB
/
test-ok-string-greaselog.config
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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
unixLogSocket: /tmp/grease.socket
sysLogSocket: /dev/log
httpUnixSocket: /tmp/maestroapi.sock
linuxKernelLog: true
processes:
reaper_interval: 1500
platform_readers:
- platform: "testplatform"
#linuxKernelLogLegacy: true # use this on kernel 3.5 and before
clientId: WWRL000001
sys_stats:
vm_stats:
every: "5s"
name: vm
disk_stats:
every: "30s"
name: disk
static_file_generators:
- name: "test_a_inline_template"
output_file: "/tmp/somedir/test_inline.out"
template: |
Hey there
DEVJS_ROOT={{DEVJS_ROOT}}
ARCH_WW_PLATFORM={{ARCH_WW_PLATFORM}} (this was from the "testplatform" platform reader)
ARCH_PAIRING_CODE={{ARCH_PAIRING_CODE}} (and so was this!)
mdns:
# disable: true
static_records:
- name: "Static"
service: "_wwservices._tcp" # normally something like https or ftp
domain: "local" # local is default
port: 313
text: [ "wwid={{RELAYID}}", "another=item" ]
hostname: "{{RELAYID}}"
- name: "MaestroStaticRecordTest2"
service: "_wwservices._tcp" # normally something like https or ftp
# domain: "local" # local is default
interfaces: "eth1,wlan1"
port: 313
text:
- "wwid={{RELAYID}}"
- "another=line"
hostname: "wigwaggateway"
watchdog:
path: "/home/ed/work/gostuff/src/github.com/PelionIoT/rallypointwatchdogs/rp100/rp100wd.so"
opt1: "/tmp/devOSkeepalive"
opt2: "30"
time_server:
host: "provisioning.mbedcloud.io"
# don't actually set the time (so we don't jack stuff up on our laptop)
pretend: true
# check every 30 seconds (totally unnecessary, use the default
# by just not setting this value - which is every 24 hours)
#check_time_interval: 30
symphony:
# symphony system management APIs
# defaults to 10:
sys_stats_count_threshold: 10
sys_stats_time_threshold: 60000
client_cert: |
-----BEGIN CERTIFICATE-----
MIIE+DCCAuCgAwIBAgIBAjANBgkqhkiG9w0BAQsFADBfMQswCQYDVQQGEwJVUzEO
MAwGA1UECAwFVGV4YXMxDzANBgNVBAcMBkF1c3RpbjEvMC0GA1UEAwwmcmVsYXlz
X3dpZ3dhZy5pb19yZWxheV9jYV9pbnRlcm1lZGlhdGUwHhcNMTgwMTEwMjM0MzEz
WhcNMzgwMTA1MjM0MzEzWjBYMQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMx
DzANBgNVBAcMBkF1c3RpbjETMBEGA1UECgwKV2lnV2FnIEluYzETMBEGA1UEAwwK
V0RSTDAwMDAwMDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAL2JtEkN
971gX+W+0ufIah5REtf6hGZgpuT8oljuQDRPtgMSLukL1xrIS32iU85dhOn28QSh
/ZnQNJWhkrpKfr7vRDqP/dxPpCXWZ3O0wP+9sFjs3W1IxWqsiA0p5EcjHCQwfpZi
g2t1UeSIFiJ89Kl8Qzh+PEapypdJWApiqdWNpQ4EuGFmQfPmcf+cfjYDlstWHp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5XgmKWKXmrKTTsZI
AkBO18Kx9TaeDNGejB5kXiz/t331xshNnsLxm0ikrNgLi42PuRptiHsND7YswGu2
/spzGDOEhrug5PQQmRkV5ZwMTHUGvUarO5NzO00CgYEA116GraG4mnD1IhIyPHQ8
8AxkfbqBq6tGV23uSXKwRhg7ClEPgA17DIOEzT+ZoiwNUCQjIqxf5V7BTRbqMhTw
W80JF7SPwM8rfsBTTG4x+EaIvm/Nb0n4+TJHaBPbYgjlkG8DkBW2ML/0t3DfO07o
F/dFzpwhf4kI2MaYgM1fFmUCgYA4f2LhH2i4yC/6uOzoA8YhwF3obz67q1bT9apV
kPcENxzLSTNcpC7HU7ZOfKUeTNsNMGvxvDFEYVjp4XVa6A0JdBR0JUy1i9oYlHeQ
ye8TDq58fstfe31i04MBPmUhIFUODl7lFstdVCpl5HecVFhDUj5BLrWn2LyOm/94
8hu8QQKBgFYvbvqDrxM7ZPqX/DxWpi/WFsxchdSSboxBRcfaPJw17dw3THvPawRO
Wua5hOijEtavBJ7MjsulNT5dc5PXjS20Y2eMZME+CkwXfQcmu90OMHd9u/2NwKuQ
DChYCcAIk+YdIAntm6ThMCHhZ4LTLXYUIY/rX39bYkqyMDM0KU3F
-----END RSA PRIVATE KEY-----
host: "devcloud-relays.wigwag.io"
var_defs:
- key: "RELAYID"
value: "WRL000001"
- key: "WIGWAG_DIR"
value: "/wigwag"
- key: "NODE_EXEC"
value: "/bin/node"
- key: "DEVJS_ROOT"
value: "/wigwag"
stats:
interval: 5 # frequency in seconds - default 300
check_mem: true # default true
check_mem_pace: 1 # means check every interval (default is 1 - every interval)
targets:
- file: /tmp/maestro.log
rotate:
max_files: 10
max_file_size: 10000
max_total_size: 100000
rotate_on_start: true
delim: "\n"
format_time: "[%ld:%d] "
format_level: "<%s> "
format_tag: "{%s} "
format_origin: "(%s) "
filters:
- levels: all
format_pre: "PRE"
# JSON file
- file: /tmp/json-maestro.log
rotate:
max_files: 10
max_file_size: 10000
max_total_size: 100000
rotate_on_start: true
delim: "],\n"
format_time: "{\"time\":\"%ld:%d\"}, "
format_level: "{\"level\":\"%s\"}, "
format_tag: "{\"tag\":\"%s\"}, "
format_origin: "{\"origin\":\"%s\"}, "
format_pre_msg: "{ \"msg\":\""
format_post: "\"}"
flag_json_escape_strings: true
filters:
- levels: all
format_pre: "[" # you will wrap this output with { "log": [ OUTPUT ] }
# format_post: "]}" # I am not sure if this works
- name: "toCloud" # this is a special target for sending to the cloud. It must send as a JSON
format_time: "\"timestamp\":%ld%03d, "
format_level: "\"level\":\"%s\", "
format_tag: "\"tag\":\"%s\", "
format_origin: "\"origin\":\"%s\", "
format_pre_msg: "\"text\":\""
format_post: "\"},"
flag_json_escape_strings: true
filters:
- levels: all
format_pre: "{" # you will wrap this output with { "log": [ OUTPUT ] }
container_templates:
- name: "deviceJS_process"
cgroup: # will implement later
mem_limit: 10000000
inherit_env: true
add_env:
- "NODE_PATH=${WIGWAG_DIR}"
exec_cmd: "/home/ed/work/devicejs-ng/.local/bin/node" # will use PATH if not absolute path (as per execvp())
exec_pre_args:
- "--max-old-space-size=128"
- "--max-semi-space-size=1"
- "deviceJSContainer"
# exec_post_args:
- name: "node_process"
cgroup: # will implement later
mem_limit: 10000000
exec_cmd: "/home/ed/work/node-8-2/node-v8.6.0-linux-x64/bin/node" # {{CMD}} will be filled in by the exec_cmd field below
exec_pre_args:
- "--max-old-space-size=128"
exec_post_args:
- "whatev"
uses_ok_string: true
- name: "node_process2"
cgroup: # will implement later
mem_limit: 10000000
exec_cmd: "/home/ed/work/node-8-2/node-v8.6.0-linux-x64/bin/node"
exec_pre_args:
- "--max-old-space-size=128"
exec_post_args:
- "whatev2"
jobs:
- job: "test_ok_string"
restart: true
exec_cmd: "{{cwd}}/auxtests/test-node-wait10s.js"
container_template: "node_process"
- job: "test_ok_string2"
restart: true
restart_limit: 2
restart_pause: 2000
exec_cmd: "{{cwd}}/auxtests/test-node-maestro-log.js"
container_template: "node_process2"
depends_on:
- "test_ok_string"
- job: "test_ok_string3"
restart: true
restart_limit: 2
restart_pause: 2000
exec_cmd: "{{cwd}}/auxtests/test-node-maestro-log.js"
container_template: "node_process2"
depends_on:
- "test_ok_string"
- job: "test_ok_string_message"
restart: true
exec_cmd: "{{cwd}}/auxtests/test-node-read-stdin.js"
container_template: "node_process2"
message: "MAGIC-START"
# - job: "test_ok_string_exit"
# exec_cmd: "{{cwd}}/auxtests/test-node-exit.js"
# container_template: "node_process"
# - job: "devicejs"
# exec_cmd: "node {{CMD}}" # {{CMD}} will be filled in by the exec_cmd field below
# exec_args:
# - "--max-executable-size=96"
# - "--max-old-space-size=128"
# - "--max-semi-space-size=1"
# - "devicejs"
# - job: "core_modules"
# container_template: "deviceJS_process"
# message: |
# "path" : "${thisdir}/../AppServer",
# "config": {}
# },
# {
# "path" : "${thisdir}/../APIProxy",
# "config": {}
# },
# {
# "path" : "${thisdir}/../core-lighting",
# "config": {}
# }
# # {
# # "path" : "${thisdir}/../UPnP",
# # "config": {}
# # },
# restart: true
# restart_limit: 5000
# restart_pause: 100 # 100 seconds between restarts
# - job: "support_tunnel"
# depends_on: # these services must be running first
# - "devicejs"
# # - "core_modules"
# restart_on_dependency_fail: true # kill the process and restart it if it's dependencies fail
# no_autostart: false # don't start it when maestro starts. But the job is available for start
# container_template: "node_process"
# exec_cmd: "/wigwag/support.js"
# exec_args:
# - "some arg"
#
# - tty: sometty
config_end: true