Export data from csv into Elasticsearch
MIT License
From csv into Elasticsearch
$ sudo pip3 install elasticfeed
elasticfeed --help
elasticfeed --host 127.0.0.1 --port 9200 --username username --password password <full filepath>
from elastic_feeder.controller import FeedElastic
fe = FeedElastic(
host="hostname or ip address",
port="port",
filename="<full path>",
index="index name",
http_auth=('username', 'password'),
properties={
"some-name": {
"type": "some-type",
},
"some-name": {
"type": "some-type",
},
"some-name": {
"type": "some-type",
}
fe.run()
First column is used as a key for data in Elasticsearch.
Linux, MacOS
Feel free to open issue and send pull request.