【发布时间】:2021-03-09 13:12:53
【问题描述】:
由于 ORM 连接失败或任何其他原因,在 OSX Catalina 中使用本地 docker/postgres 运行 Chainlink 节点非常麻烦。
使用的文档:https://docs.chain.link/docs/running-a-chainlink-node
检查我的本地数据库是否确实工作正常。我已经成功运行了这些命令:
psql postgresql://suchain:docker@127.0.0.1:5432/chainlink
psql -h localhost -U suchain -d chainlink
到目前为止已经尝试过什么
- 添加
--network host未解决连接问题
错误信息:Incorrect Usage. flag provided but not defined: -network
注意:尝试使用 --network=host - 结果相同
- 将 db_url 从 127.0.0.1 更改为 localhost
错误信息:dial error (dial tcp 127.0.0.1:5432: connect: connection refused)
- 将 localhost/127.0.0.1 更改为 docker 实例名称(如
pg-docker)
错误信息:hostname resolving error (lookup pg-docker on 192.168.65.1:53: no such host)
还可以使用哪些其他选项?
在此先感谢
在提交此之前检查了哪些页面:
【问题讨论】:
-
运行 docker 节点时,
localhost指向 docker 环境中的 localhost。 ethereum.stackexchange.com/questions/89877/…你能尝试找到你的私有或本地IP吗?否则,您可能更容易在开发模式下运行节点而不是 docker。
标签: docker blockchain psql chainlink