Inconsistent issue when using docker-compose in Bluemix

独自空忆成欢 提交于 2019-12-24 07:14:51

问题


I'm having an issue deploying and linking 3 containers using docker-compose in Bluemix / IBM Containers. The compose file I am using has worked and continues to work but it is very inconsistent. When it fails, I get the following response:

Recreating xxxxx_1
Recreating yyyyy_1
Creating zzzzz_1

ERROR: for server  'message'
Traceback (most recent call last):
  File "docker-compose", line 3, in <module>
  File "compose/cli/main.py", line 64, in main
  File "compose/cli/main.py", line 116, in perform_command
  File "compose/cli/main.py", line 876, in up
  File "compose/project.py", line 416, in up
  File "compose/parallel.py", line 66, in parallel_execute
KeyError: 'message'
Failed to execute script docker-compose

回答1:


Docker compose does not expose very good error messages (basically, when something happens it's not expecting, you get a weird stacktrace like that). My guess is that it's timing - the default timeouts on compose are expecting local docker (perhaps on very fast computers), so if things don't start very very fast, it sometimes becomes unhappy.

In the Bluemix cloud, the containers have SDN and other setup that can take a bit longer than on local docker, so that "starting very very fast" is not always within what compose expects.

Try doing export COMPOSE_HTTP_TIMEOUT=300 first to bump the timeouts, that should help matters.



来源:https://stackoverflow.com/questions/43222133/inconsistent-issue-when-using-docker-compose-in-bluemix

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!