Instantly share code, notes, and snippets.

Embed
What would you like to do?
Easy tweets collection system = Docker + Elasticsearch + Kibana + Logstash
version: '3'
services:
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch-basic:6.2.2
environment:
- discovery.type=single-node
ports:
- 9200:9200
volumes:
- ./elasticsearch/data/:/usr/share/elasticsearch/data/
networks: [elastic]
kibana:
image: docker.elastic.co/kibana/kibana:6.2.2
ports:
- 5601:5601
networks: [elastic]
logstash:
image: docker.elastic.co/logstash/logstash:6.2.2
volumes:
- ./logstash/pipeline/:/usr/share/logstash/pipeline/
networks: [elastic]
networks:
elastic:
input {
twitter {
consumer_key => "AAA"
consumer_secret => "BBB"
oauth_token => "CCC"
oauth_token_secret => "DDD"
use_samples => true
full_tweet => true
}
}
output {
elasticsearch {
hosts => ["elasticsearch"]
index => "twitter_sample_stream"
document_type => "tweet"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment