重新定义计算的边界

业界领先的企业级容器云及解决方案点此升级您的浏览器,并重新访问daocloud.io

Docker Compose

Docker Compose 可以编排多容器应用。通过 Docker Compose,你可以通过 Compose 文件来配置应用服务。 通过一条命令,您就可以启动配置中的全部服务。

Docker Compose

Docker Compose 是 Docker 官方编排(Orchestration)项目之一,负责快速在集群中部署分布式应用。 你可以也通过执行下面的命令,高速安装Docker Compose。

curl -L https://get.daocloud.io/docker/compose/releases/download/1.12.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose

你可以通过修改URL中的版本,可以自定义您的需要的版本。

1.12.0 (2017-04-04)

New features

Compose file version 3.2

  • Introduced version 3.2 of the docker-compose.yml specification.

  • Added support for cache_from in the build section of services

  • Added support for the new expanded ports syntax in service definitions

  • Added support for the new expanded volumes syntax in service definitions

Compose file version 2.1

  • Added support for pids_limit in service definitions

Compose file version 2.0 and up

  • Added --volumes option to docker-compose config that lists named volumes declared for that project

  • Added support for mem_reservation in service definitions (2.x only)

  • Added support for dns_opt in service definitions (2.x only)

All formats

  • Added a new docker-compose images command that lists images used by the current project's containers

  • Added a --stop (shorthand -s) option to docker-compose rm that stops the running containers before removing them

  • Added a --resolve-image-digests option to docker-compose config that pins the image version for each service to a permanent digest

  • Added a --exit-code-from SERVICE option to docker-compose up. When used, docker-compose will exit on any container's exit with the code corresponding to the specified service's exit code

  • Added a --parallel option to docker-compose pull that enables images for multiple services to be pulled simultaneously

  • Added a --build-arg option to docker-compose build

  • Added a --volume <volume_mapping> (shorthand -v) option to docker-compose run to declare runtime volumes to be mounted

  • Added a --project-directory PATH option to docker-compose that will affect path resolution for the project

  • When using --abort-on-container-exit in docker-compose up, the exit code for the container that caused the abort will be the exit code of the docker-compose up command

  • Users can now configure which path separator character they want to use to separate the COMPOSE_FILE environment value using the COMPOSE_PATH_SEPARATOR environment variable

  • Added support for port range to single port in port mappings (e.g. 8000-8010:80)

Bugfixes

  • docker-compose run --rm now removes anonymous volumes after execution, matching the behavior of docker run --rm.

  • Fixed a bug where override files containing port lists would cause a TypeError to be raised

  • Fixed a bug where the deploy key would be missing from the output of docker-compose config

  • Fixed a bug where scaling services up or down would sometimes re-use obsolete containers

  • Fixed a bug where the output of docker-compose config would be invalid if the project declared anonymous volumes

  • Variable interpolation now properly occurs in the secrets section of the Compose file

  • The secrets section now properly appears in the output of docker-compose config

  • Fixed a bug where changes to some networks properties would not be detected against previously created networks

  • Fixed a bug where docker-compose would crash when trying to write into a closed pipe

  • Fixed an issue where Compose would not pick up on the value of COMPOSE_TLS_VERSION when used in combination with command-line TLS flags

版本信息

发布时间:2017/04/04