Skip to content

A super simple tool for monitoring changes in log files and publishing them to MQTT

License

Notifications You must be signed in to change notification settings

adamvr/mqtt-log-monitor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mqtt-log-monitor

introduction

A super simple tool for publishing changes in log files to mqtt.
Equivalent to tail -f | sed '/^\W*$/d' | mosquitto_pub -l -t <topic>
Written in coffeescript with javascript scaffolding.

installation

npm install -g mqtt-log-monitor

usage

mqtt-log-monitor [-r] [-p port] [-h host] -f file -t topic

where:

  • -p (--port) is the port of the broker to be published to
  • -h (--host) is the hostname of the broker
  • -f (--file) is the file to monitor
  • -t (--topic) is the MQTT topic to publish changes to
  • -r (--retain) retain published messages

caveats

mqtt-log-monitor uses tail -f and has all the attendant requirements and quirks.

dependencies

About

A super simple tool for monitoring changes in log files and publishing them to MQTT

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published