Closed taowang1993 closed 1 month ago
the milvus-standalone is running, but not connecting
I found similar issues and discussions that might help you resolve the connection problem with Milvus:
The suggested solution for the MILVUS_URI
setting is to use the service name defined in the Docker Compose file instead of 127.0.0.1
or localhost
. Docker's internal DNS can resolve the correct container. For example, if the Milvus service is defined as milvus-standalone
, you should set MILVUS_URI
to http://milvus-standalone:19530
.
Update your .env
file as follows:
MILVUS_URI=http://milvus-standalone:19530
This should allow Docker to correctly route the request to the Milvus container.
Additionally, ensure that the Milvus standalone instance is correctly set up and running. Here are a few things to check:
ETCD_ENDPOINTS
and MINIO_ADDRESS
are correctly set and the services they point to are running.19530
and 9091
are correctly mapped and not used by other services.http://localhost:9091/healthz
.etcd
and minio
services are up and running since Milvus depends on them.uri
, user
, and password
.For more details, you can refer to the Dify documentation and the .env.example
file in the repository [4][5][6][7].
To continue talking to Dosu, mention @dosu.
See #8019
I added networks to the worker and api containers. Now it is working. And I specified the URI as MILVUS_URI=http://milvus-standalone:19530
name: dify
services: api: image: langgenius/dify-api:latest networks:
milvus
worker: image: langgenius/dify-api:latest networks:
milvus
web: image: langgenius/dify-web:latest
Self Checks
Dify version
0.8.3
Cloud or Self Hosted
Self Hosted (Docker)
Steps to reproduce
VECTOR_STORE=milvus MILVUS_URI=http://127.0.0.1:19530 MILVUS_TOKEN= MILVUS_USER=root MILVUS_PASSWORD=Milvus
✔️ Expected Behavior
No response
❌ Actual Behavior
No response