Open ThanhTu130200 opened 1 year ago
That means that the host cannot find by ip automatically, you should specify the instance_host
in init
method.
eureka_client.init(eureka_server="http://localhost:8761/eureka/", app_name="Service4", instance_port=5000, instance_host="127.0.0.1")🙃
I ran to this error when registry to java eureka server:
WARNING: Error when getting host by ip Traceback (most recent call last): File "C:\Users\ASUS\AppData\Local\Programs\Python\Python38\lib\site-packages\py_eureka_client\netint_utils.py", line 35, in get_host_by_ip return socket.gethostbyaddr(ip)[0] socket.herror: [Errno 11004] host not found
And here is my code: