Docker 中的 Orion 无法与累加器服务器通信:本地主机通知失败
Orion in Docker can not communicate with accumulator-server: Notification failure for localhost
我正在使用 docker-compose
到 运行 Orion+Mongo。
然后,我开始accumulator-server
:
drasko@Lenin:~/fiware/fiware-orion/scripts$ ./accumulator-server.py 1028 /accumulate on
verbose mode is on
* Running on http://0.0.0.0:1028/ (Press CTRL+C to quit)
但是运行ning a给出了错误:
orion_1 | WARNING@21:27:21 httpRequestSend.cpp[438]: Notification failure for localhost:1028 (curl_easy_perform failed: Couldn't connect to server)
难道是Orion在Docker中运行的缘故,如何解决这个问题?
您的问题是您的 Orion 主机无法到达累加器。
在订阅中,您正在使用值为 "localhost" 的引用字段,因此 Orion 正在查找相对于 docker 容器的本地主机。
要解决它,您应该 运行 docker 图像中的蓄能器,或者让 Orion 能够以 "localhost" 以外的其他方式联系蓄能器(也许 运行 不同容器中的累加器和 link 它使用 docker 组合)。
我正在使用 docker-compose
到 运行 Orion+Mongo。
然后,我开始accumulator-server
:
drasko@Lenin:~/fiware/fiware-orion/scripts$ ./accumulator-server.py 1028 /accumulate on
verbose mode is on
* Running on http://0.0.0.0:1028/ (Press CTRL+C to quit)
但是运行ning a给出了错误:
orion_1 | WARNING@21:27:21 httpRequestSend.cpp[438]: Notification failure for localhost:1028 (curl_easy_perform failed: Couldn't connect to server)
难道是Orion在Docker中运行的缘故,如何解决这个问题?
您的问题是您的 Orion 主机无法到达累加器。
在订阅中,您正在使用值为 "localhost" 的引用字段,因此 Orion 正在查找相对于 docker 容器的本地主机。
要解决它,您应该 运行 docker 图像中的蓄能器,或者让 Orion 能够以 "localhost" 以外的其他方式联系蓄能器(也许 运行 不同容器中的累加器和 link 它使用 docker 组合)。