Skip to content

Instantly share code, notes, and snippets.

@pokev25
Last active May 2, 2017 11:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pokev25/696729a91f25f1e010606bf3143b5421 to your computer and use it in GitHub Desktop.
Save pokev25/696729a91f25f1e010606bf3143b5421 to your computer and use it in GitHub Desktop.
logstash 설정
input {
redis {
host => "192.168.0.20"
data_type => "list"
key => "key1"
codec => "json"
db => 3
type => "key1"
}
}
output {
if [type] == "key1" {
elasticsearch {
hosts => "192.168.0.20:9200"
index => "key1-%{+YYYY.MM.dd}"
document_type => "log"
}
}
}
input {
redis {
host => "192.168.0.20"
data_type => "list"
key => "key2"
codec => "json"
db => 3
type => "key2"
}
}
output {
if [type] == "key2" {
elasticsearch {
hosts => "192.168.0.20:9200"
index => "key2-%{+YYYY.MM.dd}"
document_type => "log"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment