VSTS docker 编写任务
VSTS docker compose task
我正在尝试使用 VSTS 和 docker-compose 配置持续交付,我想将其推送到 Azure 容器注册表。
这是我在 VSTS 上的构建定义:
我在构建结果中收到一条错误消息:
No such command: docker_compose
Commands:
build Build or rebuild services
bundle Generate a Docker bundle from the Compose file
config Validate and view the Compose file
create Create services
down Stop and remove containers, networks, images, and volumes
events Receive real time events from containers
exec Execute a command in a running container
help Get help on a command
你知道我该如何处理吗?
更新:
这是我的 docker-compose
version: '3'
services:
ci-build:
image: microsoft/aspnetcore-build:1.0-1.1
volumes:
- .:/src
working_dir: /src
command: /bin/bash -c "dotnet restore ./Travelingowe.sln && dotnet publish ./Travelingowe.sln -c Release -o ./obj/Docker/publish"
仅使用 up
而不是 docker-compose up
。我自己也遇到了同样的问题。
我正在尝试使用 VSTS 和 docker-compose 配置持续交付,我想将其推送到 Azure 容器注册表。
这是我在 VSTS 上的构建定义:
我在构建结果中收到一条错误消息:
No such command: docker_compose
Commands:
build Build or rebuild services
bundle Generate a Docker bundle from the Compose file
config Validate and view the Compose file
create Create services
down Stop and remove containers, networks, images, and volumes
events Receive real time events from containers
exec Execute a command in a running container
help Get help on a command
你知道我该如何处理吗?
更新: 这是我的 docker-compose
version: '3'
services:
ci-build:
image: microsoft/aspnetcore-build:1.0-1.1
volumes:
- .:/src
working_dir: /src
command: /bin/bash -c "dotnet restore ./Travelingowe.sln && dotnet publish ./Travelingowe.sln -c Release -o ./obj/Docker/publish"
仅使用 up
而不是 docker-compose up
。我自己也遇到了同样的问题。