Logstash 5.0.0 supported plugin. (Forked from: https://github.com/cyli/logstash-output-slack)
Uses Slack incoming webhooks API to send log events to Slack.
Usage:
input {
...
}
filters {
...
}
output {
...
slack {
url => <YOUR SLACK WEBHOOK URL HERE>
channel => [channel-name - optional]
username => [slack username - optional]
icon_emoji => [emoji, something like ":simple_smile:" - optional]
icon_url => [icon url, would be overriden by icon_emoji - optional]
format => [default is "%{message}", but used to format the text - optional]
attachments => [an array of attachment maps as specified by the slack API - optional; if there is an "attachments" field in the event map and it is valid, it will override what is configured here, even if it's empty]
}
}
- v0.1.5:
- Support logstash 5.0.0
- v0.1.4:
- v0.1.3:
- No change - bug in releasing
- v0.1.2:
- Added support for attachments
- v0.1.1:
- v0.1.0:
- initial version containing basic slack functionality
This forked plugin is not deployed yet, so you need to build it.
- Install logstash 5.0.0
- Install JRuby
jruby -S gem install bundler
git clone <thisrepo>
jruby -S bundle install
jruby -S gem build logstash-output-slack.gemspec
logstash-plugin install --no-verify
bin/plugin list | grep logstash-output-slack
bin/logstash -e '
input { stdin {} }
output { slack { <your slack config here> }}'
And type some text in. The same text should appear in the channel it's configured to go in.
Not supported.