Use external configuration for the log to monitor

This commit is contained in:
Fabio Salvini
2017-07-01 19:57:03 +02:00
parent fa1bfa9d25
commit 1e26998649
9 changed files with 164 additions and 64 deletions

View File

@@ -16,7 +16,8 @@
{password, ""}]
}
]
}
},
{logfiles_config, "/home/fsalvini/gitRepos/log_monitor/config/logfiles.config"}
]
},
%% Directory where the application data is stored.

12
config/logfiles.config Normal file
View File

@@ -0,0 +1,12 @@
{monitored_logs, [
{
{group, "Test"},
{email_receivers, ["user@example.com"]},
{logfiles, [
{
{file, "/tmp/lines.log"},
{error_regex, "ERROR"}
}
]}
}
]}.

1
config/rebar.lock Normal file
View File

@@ -0,0 +1 @@
[].