fluent-plugin-mail 0.2.2 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.travis.yml +2 -0
- data/CHANGELOG.md +7 -0
- data/fluent-plugin-mail.gemspec +2 -1
- data/lib/fluent/plugin/out_mail.rb +32 -2
- metadata +5 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f383ef142caab20f8176e6c38e7cf774ed5d1a4d
|
|
4
|
+
data.tar.gz: a5006e52c3e4a0fde6b7c713f245fdf44b5b07c9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 81aca182ab3d260cbea3f57294a648770a22278d5fa525f69be6eb4448b1df75646faea58e7b3a1c77d100042314cae6a308cd1a9b1964c48e3e0414d8578a3c
|
|
7
|
+
data.tar.gz: d412c15b6df8914e240b7491e5085b45031a5aaca8de4012d8d3833be7f442480545bfbd17b68fd81ae10e465b6a7e6d735ed9286e93b4fe3fe758d583dd629a
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
data/fluent-plugin-mail.gemspec
CHANGED
|
@@ -12,7 +12,8 @@ Gem::Specification.new do |gem|
|
|
|
12
12
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
|
13
13
|
gem.name = "fluent-plugin-mail"
|
|
14
14
|
gem.require_paths = ["lib"]
|
|
15
|
-
gem.version = '0.2.
|
|
15
|
+
gem.version = '0.2.3'
|
|
16
|
+
gem.license = "Apache-2.0"
|
|
16
17
|
|
|
17
18
|
gem.add_runtime_dependency "fluentd"
|
|
18
19
|
gem.add_runtime_dependency "string-scrub" if RUBY_VERSION.to_f < 2.1
|
|
@@ -8,32 +8,62 @@ class Fluent::MailOutput < Fluent::Output
|
|
|
8
8
|
define_method("log") { $log }
|
|
9
9
|
end
|
|
10
10
|
|
|
11
|
+
# For fluentd v0.12.16 or earlier
|
|
12
|
+
class << self
|
|
13
|
+
unless method_defined?(:desc)
|
|
14
|
+
def desc(description)
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
desc "Output comma delimited keys"
|
|
11
20
|
config_param :out_keys, :string, :default => ""
|
|
21
|
+
desc "Format string to construct message body"
|
|
12
22
|
config_param :message, :string, :default => nil
|
|
23
|
+
desc "Specify comma delimited keys output to `message`"
|
|
13
24
|
config_param :message_out_keys, :string, :default => ""
|
|
25
|
+
desc "Identify the timestamp of the record"
|
|
14
26
|
config_param :time_key, :string, :default => nil
|
|
27
|
+
desc "Identify the tag of the record"
|
|
15
28
|
config_param :tag_key, :string, :default => 'tag'
|
|
29
|
+
desc "SMTP server hostname"
|
|
16
30
|
config_param :host, :string
|
|
31
|
+
desc "SMTP server port number"
|
|
17
32
|
config_param :port, :integer, :default => 25
|
|
33
|
+
desc "HELO domain"
|
|
18
34
|
config_param :domain, :string, :default => 'localdomain'
|
|
35
|
+
desc "User for SMTP Auth"
|
|
19
36
|
config_param :user, :string, :default => nil
|
|
37
|
+
desc "Password for SMTP Auth"
|
|
20
38
|
config_param :password, :string, :default => nil, :secret => true
|
|
39
|
+
desc "MAIL FROM this value"
|
|
21
40
|
config_param :from, :string, :default => 'localhost@localdomain'
|
|
41
|
+
desc "Mail destination (To)"
|
|
22
42
|
config_param :to, :string, :default => ''
|
|
43
|
+
desc "Mail destination (Cc)"
|
|
23
44
|
config_param :cc, :string, :default => ''
|
|
45
|
+
desc "Mail destination (BCc)"
|
|
24
46
|
config_param :bcc, :string, :default => ''
|
|
47
|
+
desc "Format string to construct mail subject"
|
|
25
48
|
config_param :subject, :string, :default => 'Fluent::MailOutput plugin'
|
|
49
|
+
desc "Specify comma delimited keys output to `subject`"
|
|
26
50
|
config_param :subject_out_keys, :string, :default => ""
|
|
51
|
+
desc "If set to true, enable STARTTLS"
|
|
27
52
|
config_param :enable_starttls_auto, :bool, :default => false
|
|
53
|
+
desc "If set to true, enable TLS"
|
|
28
54
|
config_param :enable_tls, :bool, :default => false
|
|
55
|
+
desc "Format string to parse time"
|
|
29
56
|
config_param :time_format, :string, :default => "%F %T %z"
|
|
57
|
+
desc "Use local time or not"
|
|
30
58
|
config_param :localtime, :bool, :default => true
|
|
59
|
+
desc "Locale of time"
|
|
31
60
|
config_param :time_locale, :default => nil
|
|
61
|
+
desc "Specify Content-Type"
|
|
62
|
+
config_param :content_type, :string, :default => "text/plain; charset=utf-8"
|
|
32
63
|
|
|
33
64
|
def initialize
|
|
34
65
|
super
|
|
35
66
|
require 'net/smtp'
|
|
36
|
-
require 'kconv'
|
|
37
67
|
require 'string/scrub' if RUBY_VERSION.to_f < 2.1
|
|
38
68
|
end
|
|
39
69
|
|
|
@@ -179,7 +209,7 @@ Bcc: #{@bcc}
|
|
|
179
209
|
Subject: #{subject}
|
|
180
210
|
Message-Id: #{mid}
|
|
181
211
|
Mime-Version: 1.0
|
|
182
|
-
Content-Type:
|
|
212
|
+
Content-Type: #{@content_type}
|
|
183
213
|
|
|
184
214
|
#{body}
|
|
185
215
|
EOF
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fluent-plugin-mail
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Yuichi UEMURA
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2015-
|
|
12
|
+
date: 2015-12-29 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: fluentd
|
|
@@ -75,7 +75,8 @@ files:
|
|
|
75
75
|
- test/helper.rb
|
|
76
76
|
- test/plugin/test_out_mail.rb
|
|
77
77
|
homepage: https://github.com/u-ichi/fluent-plugin-mail
|
|
78
|
-
licenses:
|
|
78
|
+
licenses:
|
|
79
|
+
- Apache-2.0
|
|
79
80
|
metadata: {}
|
|
80
81
|
post_install_message:
|
|
81
82
|
rdoc_options: []
|
|
@@ -93,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
93
94
|
version: '0'
|
|
94
95
|
requirements: []
|
|
95
96
|
rubyforge_project: fluent-plugin-mail
|
|
96
|
-
rubygems_version: 2.
|
|
97
|
+
rubygems_version: 2.5.1
|
|
97
98
|
signing_key:
|
|
98
99
|
specification_version: 4
|
|
99
100
|
summary: output plugin for Mail
|