2016-08-16 96 views
2

我收到錯誤的‘錯誤:客戶端和服務器不具有相同的版本(客戶端:1.21,服務器:1.18)’錯誤而跑「泊塢窗,構成了

於是我就命令」出口COMPOSE_API_VERSION = 1.18" ,現在我得到不同的錯誤

Traceback (most recent call last): 
File "<string>", line 3, in <module> 
File "compose/cli/main.py", line 61, in main 
File "compose/cli/main.py", line 113, in perform_command 
File "compose/cli/main.py", line 835, in up 
File "compose/project.py", line 374, in up 
File "compose/project.py", line 415, in initialize 
File "compose/network.py", line 162, in initialize 
File "compose/network.py", line 47, in ensure 
File "compose/network.py", line 82, in inspect 
File "site-packages/docker/utils/decorators.py", line 32, in wrapper 
docker.errors.InvalidVersion: inspect_network is not available for version < 1.21 
docker-compose returned -1 

我的搬運工,撰寫文件可以在 gist

泊塢版本中找到:泊塢版本1.12.0,構建8eab29e

Docker-compose:docker-compose 1.8.0版,build f3628c7

Ubuntu 14.04 64bit。

任何幫助,將不勝感激。謝謝。

回答

-1

您正在本地運行docker(1.12)和docker-compose(1.8.0)的最新版本。錯誤消息意味着您可能正在遠程服務器上啓動容器? (開始於docker-machine?)

我建議升級在目標服務器上運行的docker版本。

關於COMPOSE_API_VERSION variable的文檔聲明只能用作解決方法。

Setting this variable is intended as a workaround for situations where you need to run temporarily with a mismatch between the client and server version. For example, if you can upgrade the client but need to wait to upgrade the server.

Running with this variable set and a known mismatch does prevent some Docker features from working properly. The exact features that fail would depend on the Docker client and server versions. For this reason, running with this variable set is only intended as a workaround and it is not officially supported.

If you run into problems running with this set, resolve the mismatch through upgrade and remove this setting to see if your problems resolve before notifying support.