u-ichi / fluent-plugin-mail

Fluentd output plugin to send mail
https://rubygems.org/gems/fluent-plugin-mail
Other
48 stars 20 forks source link

Hi,I found this plugin can't work #16

Closed liuxiong21 closed 9 years ago

liuxiong21 commented 9 years ago

I want to send mail that mail body content get from fluentd log record's field value.

My configure is as follows:

<match error.**>
    type mail
    host smtp.exmail.qq.com #This is for Gmail and Google Apps. Any SMTP server should work
    port 25 #This is the port for smtp.gmail.com
    user liuxiong@souche.com #I work here! Use YOUR EMAIL.
    password lx2014 #I can't tell you this! Use YOUR PASSWORD!
    from xxxx@xxxx.com
    to xxxxx@xxxx.com
    subject Log Monitor Alert: %s
    subject_out_keys project
    out_keys msg,class,level
</match>

I receive email subject is:Log Monitor Alert: content is: msg: class: level:

sonots commented 9 years ago

Hi, can you show me the incomming message? You can log it with configuration like

<match foo.bar>
  type copy
  <store>
    type stdout
  </store>
  <store>
    type mail
    blah blah
  </store>
</match>

I am guesing as the incoming message is invalid.

liuxiong21 commented 9 years ago

thks Yes,I found problem from stdout output log,That grepcounter plugin not send entire original log object to mail plugin。

sonots commented 9 years ago

So, it is not the problem of fluent-plugin-mail. Please re-think how to combine them well.

sonots commented 9 years ago

Let me close.

github-zhang commented 7 years ago

have problems?

<match .> type mail host smtp.gmail.com port 587 domain gmail.com from @gmail.com to ****@qq.com subject testsubjct user 9@gmail.com password ***** enable_starttls_auto true enable_tls false out_keys tag,foo,message time_locale UTC