반응형
Recent Posts
Recent Comments
관리 메뉴

개발잡부

[python] python elasticsearch client 본문

Python

[python] python elasticsearch client

닉의네임 2022. 4. 28. 23:05
반응형

파이썬 Elasticsearch client 생성

회사 ES 계속 에러남 .. 3번째로 시도해 봐야겠음

client = Elasticsearch([{'host': config.elastic_host, 'port': config.elastic_port}])
client = Elasticsearch(http_auth=('elastic', 'dlengus'))
client = Elasticsearch(["http://elastic:dlengus@localhost:9200"])
client = Elasticsearch("https://elastic:password@회사.co.kr:443/", ca_certs=False )

 

당췌 뭐가 문제인지.. 

  File "/Users/doo/opt/anaconda3/envs/doo/lib/python3.7/site-packages/elasticsearch/_sync/client/__init__.py", line 379, in __init__
    **transport_kwargs,
  File "/Users/doo/opt/anaconda3/envs/doo/lib/python3.7/site-packages/elastic_transport/_transport.py", line 233, in __init__
    **node_pool_kwargs,
  File "/Users/doo/opt/anaconda3/envs/doo/lib/python3.7/site-packages/elastic_transport/_node_pool.py", line 188, in __init__
    self._all_nodes[node_config] = self._node_class(node_config)
  File "/Users/doo/opt/anaconda3/envs/doo/lib/python3.7/site-packages/elastic_transport/_node/_http_urllib3.py", line 98, in __init__
    "Root certificates are missing for certificate "
ValueError: Root certificates are missing for certificate validation. Either pass them in using the ca_certs parameter or install certifi to use it automatically.
반응형
Comments