導入數(shù)據(jù)至數(shù)據(jù)集時報錯Meta endpoint! Unexpected status code: 502, with response body: None.
我的dify服務器是在內(nèi)網(wǎng)環(huán)境,首先它需要通過代理去調(diào)用 LLM,但打開代理后調(diào)用 dify weaviate 服務會報錯:Meta endpoint! Unexpected status code: 502, with response body: None. 所以,需要做的是:既要在調(diào)用LLM的時候走代理,又要調(diào)用 dify weaviate 服務的時候不走代理。 配置如下:
dify 是通過 docker compose 的方式運行起來的, 所以需要編輯 dify 的 docker-compose.yaml 文件。
... services: # API service api: image: langgenius/dify-api:0.7.1 restart: always environment: # Use the shared environment variables. <<: *shared-api-worker-env # Startup mode, 'api' starts the API server. MODE: api # 設置代理 HTTP_PROXY: http://my-proxy.com:3128 HTTPS_PROXY: http://my-proxy.com:3128 # 不走代理的情況: 把 weaviate 服務添加到里面 NO_PROXY: localhost,127.0.0.1,weaviate depends_on: - db - redis volumes: # Mount the storage directory to the container, for storing user files. - ./volumes/app/storage:/app/api/storage networks: - ssrf_proxy_network - default # worker service # The Celery worker for processing the queue. worker: image: langgenius/dify-api:0.7.1 restart: always environment: # Use the shared environment variables. <<: *shared-api-worker-env # Startup mode, 'worker' starts the Celery worker for processing the queue. MODE: worker # 設置代理 HTTP_PROXY: http://my-proxy.com:3128 HTTPS_PROXY: http://my-proxy.com:3128 # 不走代理的情況: 把 weaviate 服務添加到里面 NO_PROXY: localhost,127.0.0.1,weaviate depends_on: - db - redis volumes: # Mount the storage directory to the container, for storing user files. - ./volumes/app/storage:/app/api/storage networks: - ssrf_proxy_network - default # dify 的其他服務就不需要配置代理的設置了 ...
參考鏈接:
https://github.com/langgenius/dify/issues/4736
https://github.com/langgenius/dify/issues/734
Code your future.

浙公網(wǎng)安備 33010602011771號