flog icon indicating copy to clipboard operation
flog copied to clipboard

Feature Request: Output logs to network connection

Open asachs01 opened this issue 3 years ago • 3 comments

As a flog user, I'd like to be able to use it to send test logs to a log management system like Splunk or Graylog. Presently, I have to output to a file, or try and netcat the output to a specific endpoint, which seems rather cumbersome. Adding the ability to directly output to a given endpoint (like an IP/hostname) would shorten the amount of steps I need to take to send flogs logs off.

asachs01 avatar Jan 13 '21 18:01 asachs01

You can output the logs to stdout (default mode), and pipe the output to network connections.

$ flog -n 100 | nc ...

mingrammer avatar Jan 23 '21 12:01 mingrammer

@mingrammer Right, completely doable and it's what I'm currently doing. But it would be nice to have a --host sort of option to be able to specify a remote host rather than using nc.

asachs01 avatar Feb 08 '21 16:02 asachs01

@asachs01 this feature will add unnecessary complexity. if you don't want to use pipes with netcat, you can wrap it into a bash script with arguments.

lebe-dev avatar May 28 '23 07:05 lebe-dev