Skip to content

Instantly share code, notes, and snippets.

@acidlemon
Created May 7, 2013 10:56
Show Gist options
  • Save acidlemon/5531810 to your computer and use it in GitHub Desktop.
Save acidlemon/5531810 to your computer and use it in GitHub Desktop.
原始的なfluentd configtest
require 'rubygems'
require 'fluent/config'
obj = Fluent::Config.read(ARGV[0])
if obj then
print "config is OK\n"
else
print "config has some errors\n"
end
@acidlemon
Copy link
Author

なお、設定ファイルに文法エラーがあると parse error at fluentd.conf line 5 (Fluent::ConfigParseError) となって
そもそもsome errorsまで行かないのであんまりelseに意味は無いかもしれない('-'o)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment