File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,14 @@ function run() {
2626 dbg . log0 ( 'SERVER_MONITOR: BEGIN' ) ;
2727 monitoring_status = {
2828 dns_status : "UNKNOWN" ,
29- ph_status : "UNKNOWN" ,
29+ ph_status : {
30+ status : "UNKNOWN" ,
31+ test_time : moment ( ) . unix ( )
32+ } ,
33+ remote_syslog_status : {
34+ status : "UNKNOWN" ,
35+ test_time : moment ( ) . unix ( )
36+ }
3037 } ;
3138 if ( ! system_store . is_finished_initial_load ) {
3239 dbg . log0 ( 'waiting for system store to load' ) ;
@@ -236,7 +243,6 @@ function _check_remote_syslog() {
236243 dbg . log2 ( '_check_remote_syslog' ) ;
237244 let system = system_store . data . systems [ 0 ] ;
238245 if ( _ . isEmpty ( system . remote_syslog_config ) ) return ;
239- monitoring_status . remote_syslog_status = "UNKNOWN" ;
240246 if ( _ . isEmpty ( system . remote_syslog_config . address ) ) return ;
241247 monitoring_status . remote_syslog_status = {
242248 test_time : moment ( ) . unix ( )
@@ -246,7 +252,7 @@ function _check_remote_syslog() {
246252 monitoring_status . remote_syslog_status . status = "OPERATIONAL" ;
247253 } )
248254 . catch ( err => {
249- monitoring_status . remote_syslog_status = "UNREACHABLE" ;
255+ monitoring_status . remote_syslog_status . status = "UNREACHABLE" ;
250256 dbg . warn ( 'Error when trying to check remote syslog status.' , err . stack || err ) ;
251257 } ) ;
252258}
You can’t perform that action at this time.
0 commit comments