gogstash
gogstash copied to clipboard
file output module
I'm trying to move from logstash to gogstash but one of the things that's preventing me from moving is the lack of the file output module.
Is there anything in the works to support this? Would you have any tips/pointers in case I try to implement this myself? I'm happy to try to get this working but I'm sure I can save some time using your initial direction/tips.
There is no file output currently, you can view output/stdout
and implement the file output base on it.
thanks, I'll give it a try. I'm having trouble getting a clean checkout to build. Is there any particular commit I should be using?
If I checkout master, do a dep ensure and try go build main.go I get the following errors:
gogstash/vendor/github.com/tsaikd/gogstash/config/goglog vendor/github.com/tsaikd/gogstash/config/goglog/goglog.go:20:2: unknown field 'RuntimeCallerFilters' in struct literal of type logrusutil.ConsoleLogFormatter gogstash/vendor/github.com/docker/docker/opts vendor/github.com/docker/docker/opts/address_pools.go:15:12: undefined: ipamutils.NetworkToSplit
If try to build the 0.1.16 source using godep restore I get the following error instead:
go/src/github.com/go-fsnotify/fsnotify; git checkout 629574ca2a5df945712d3079857300b5e4da0236 fatal: reference is not a tree: 629574ca2a5df945712d3079857300b5e4da0236 godep: error downloading dep (github.com/go-fsnotify/fsnotify): exit status 128 godep: Error downloading some deps. Aborting restore and check.
any suggestions?
I’m using go get -u instead of godep. Maybe godep is broken now
2019年4月12日(金) 5:38 horacimacias [email protected]:
thanks, I'll give it a try. I'm having trouble getting a clean checkout to build. Is there any particular commit I should be using?
If I checkout master, do a dep ensure and try go build main.go I get the following errors:
gogstash/vendor/github.com/tsaikd/gogstash/config/goglog
vendor/github.com/tsaikd/gogstash/config/goglog/goglog.go:20:2: unknown field 'RuntimeCallerFilters' in struct literal of type logrusutil.ConsoleLogFormatter gogstash/vendor/github.com/docker/docker/opts
vendor/github.com/docker/docker/opts/address_pools.go:15:12: undefined: ipamutils.NetworkToSplit
If try to build the 0.1.16 source using godep restore I get the following error instead:
go/src/github.com/go-fsnotify/fsnotify; git checkout 629574ca2a5df945712d3079857300b5e4da0236 fatal: reference is not a tree: 629574ca2a5df945712d3079857300b5e4da0236 godep: error downloading dep (github.com/go-fsnotify/fsnotify): exit status 128 godep: Error downloading some deps. Aborting restore and check.
any suggestions?
— You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/tsaikd/gogstash/issues/81#issuecomment-482331080, or mute the thread https://github.com/notifications/unsubscribe-auth/AAOCYVHF3QETYUG6JVIJSWLPP6VU5ANCNFSM4HFGX2ZQ .
I tried to use file module:
output:
- type: stdout
- type: file
path: /logging/ip_test.log
but for me it just printed: tail -f /logging/ip_test.log
%{log}
%{log}
%{log}
%{log}
looks like file output module doesn't work
Have a look at the documentation for the output module. You need to specify the output format to tell what fields you want written to a file and the format for it.