目前,當我這樣做幾乎任何泊塢窗命令(例如docker ps
)我收到以下錯誤信息:如何在Docker中快速設置默認環境?
An error occurred trying to connect: Get http://%2F%2F.%2Fpipe%2Fdocker_engine/v1.23/containers/json: open //./pipe/docker_engine: The system cannot find the file specified.
爲了解決這個問題,我已經運行下面的命令:
@FOR /f "tokens=*" %i IN ('docker-machine env') DO @%i
監守我做經常這樣做,我決定把這個腳本叫做setup-docker-env.bat
但是每當我運行這個腳本時,我得到以下錯誤:
i was unexpected at this time.
這很奇怪,因爲它在命令行上工作。
打我吧:) – mandark