Skip to content

Repository files navigation

qremlin

This silly little project provides remote access to a specified list of log files. Chances are it won't ever be used, but it fills a current need in a very lightweight way and is therefore worth exploring.

Usage

qremlin -filelist=/etc/qremlin-filelist.conf -listen=0.0.0.0:64646 -bufsize=1024

All arguments are options; default values are shown above.

API

Valid URLs are:

  • /<fileId>
    Download the file.
  • /<fileId>/tail
    Tail the file. Polls once per second for changes to the file, and uses chunked encoding to send it to the client.

The first URL can take a query parameter of n which indicates the number of lines to return from the end of the file.

Both URLs can take a query parameter of q which specifies a string by which to filter the lines returned.

TODO

  • Tests and testing.
  • Support regular expression queries.
  • Websocket support for tailing.
  • Format dates into the log filenames.
  • Optionally download prepend previously rotated log files when downloading.

License

Do whatever you want with this thing. Pull requests welcome.

About

Remote log file access.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages