我正在尝试将我的容器生成的日志重定向到另一个持有ELK的容器,但是我收到了这个错误:
ERROR: for uid-manager Failed to initialize logging driver: gelf: cannot connect to GELF endpoint: elk_stack:12201 dial udp: lookup elk_stack: no such host
这是我的配置:
version: '2'
services:
elk_stack:
image: sebp/elk
container_name: elk_stack
ports:
- "5601:5601"
- "9200:9200"
- "12201:12201/udp"
expose:
- "5601"
- "9200"
- "12201/udp"
uid-manager:
image: uid-manager-server:latest
container_name: uid-manager
ports:
- "15100:15100"
- "9111:9111"
expose:
- "15100"
- "9111"
logging:
driver: gelf
options:
gelf-address: "udp://elk_stack:12201"
environment:
- [...]
links:
- elk_stack
你能告诉我我做错了什么吗?谢谢!