我正在尝试使用elasticsearch 7和mongo 4使用docker-compose进行本地设置。我在研究麦克。这是我的docker-compose.yml:https://gist.github.com/gandra/dc649b37e165d8e3fc5b20c30a8b5a79
跑完后:
docker-compose up -d --build当打开我看到的url时,我看不到http://localhost:9000/上的任何数据:
localhost didn’t send any data.
ERR_EMPTY_RESPONSE知道怎么让它起作用吗?
发布于 2021-05-19 03:25:41
下面是我在我的项目中使用的使其工作的配置(编写v3)。
###################################
# Greylog container logging start #
###################################
# Taken from https://docs.graylog.org/en/4.0/pages/installation/docker.html
# MongoDB: https://hub.docker.com/_/mongo/
mongo:
image: mongo:4.2
# Elasticsearch: https://www.elastic.co/guide/en/elasticsearch/reference/7.10/docker.html
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch-oss:7.10.2
environment:
- http.host=0.0.0.0
- transport.host=localhost
- network.host=0.0.0.0
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
deploy:
resources:
limits:
memory: 1g
# Graylog: https://hub.docker.com/r/graylog/graylog/
graylog:
image: graylog/graylog:4.0
environment:
# CHANGE ME (must be at least 16 characters)!
- GRAYLOG_PASSWORD_SECRET=somepasswordpepper
# Password: admin
- GRAYLOG_ROOT_PASSWORD_SHA2=8c6976e5b5410415bde908bd4dee15dfb167a9c873fc4bb8a81f6f2ab448a918
- GRAYLOG_HTTP_EXTERNAL_URI=http://127.0.0.1:9000/
entrypoint: /usr/bin/tini -- wait-for-it elasticsearch:9200 -- /docker-entrypoint.sh
restart: always
depends_on:
- mongo
- elasticsearch
ports:
# Graylog web interface and REST API
- 9000:9000
# Syslog TCP
- 1514:1514
# Syslog UDP
- 1514:1514/udp
# GELF TCP
- 12201:12201
# GELF UDP
- 12201:12201/udp
###################################
# Greylog container logging end #
###################################我要说,这需要相当长的时间才能开始。输出日志运行了一段时间,而Graylog、MongoDB和El154搜索完成了它们的设置工作。但是,在它的结尾,它最终还是可用了(大约花了两分钟)。不过,在它准备好之前,我看到了和你一样的反应。
发布于 2021-05-12 14:27:39
Graylog不支持Elasticsearch版本7.11或更高版本,因此需要将Elasticsearch版本更改为7.10.2。除此之外,你在Graylog的server.log中看到了什么?
https://stackoverflow.com/questions/67503261
复制相似问题