我有两个 e2e 自动化框架,一个是基于 python 的,另一个是基于量角器的。我需要编写一个 docker-compose 文件来在不同的容器中运行这两个项目,并将报告及其控制台获取到我的本地系统。
下面是我的 docker-compose.yml 文件的内容
version: '3'
services:
e2e-Tests:
build: ./c8y/DockerFile
image: e2etests
command: npm run e2e
container_name: cn-e2eTests
py-Tests:
build: ./py/DockerFile
image: pytests
command: npm run e2e
container_name: cn-pyTests
当我运行 docker-compose up 时,出现以下错误:
Building e2e-Tests
failed to get console mode for stdout: The handle is invalid.
[+] Building 0.0s (0/1)
[+] Building 0.0s (1/2) om sender: walk \\?\C:\Users\xxx\e2e\Dockerfile: The system cannot find the path specified.
=> ERROR [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 105B 0.0s
------
> [internal] load build definition from Dockerfile:
------
ERROR: Service 'e2e-Tests' failed to build
答案 0 :(得分:1)
尝试重命名:Dockerfile
而不是 DockerFile
。
编辑:
如果未明确提供 docker 文件名,它将查找带有小 Dockerfile
的文件 f
。我的问题就是这么简单。
答案 1 :(得分:0)
我的问题与注册表访问问题有关。现在运行正常。