在docker容器内运行delve-debug.test:没有这样的文件或目录
当尝试在现有项目的docker容器中运行delve时,我们得到以下结果:在docker容器内运行delve-debug.test:没有这样的文件或目录,docker,go,remote-debugging,delve,Docker,Go,Remote Debugging,Delve,当尝试在现有项目的docker容器中运行delve时,我们得到以下结果: API server listening at: [::]:4040 could not launch process: fork/exec /go/src/github.com/marcosvpj/rey/debug.test: no such file or directory could not remove /go/src/github.com/marcosvpj/rey/debug.test: remove /g
API server listening at: [::]:4040
could not launch process: fork/exec /go/src/github.com/marcosvpj/rey/debug.test: no such file or directory
could not remove /go/src/github.com/marcosvpj/rey/debug.test: remove /go/src/github.com/marcosvpj/rey/debug.test: no such file or directory
尝试在一个全新的项目中运行,使用相同的Dockerfile,一切正常。
查找了文件debug.test,但在两个容器中都找不到
有人知道我需要找什么吗
我得到的最接近的答案是FAQ,它表明需要在docker运行中使用--security opt=seccomp:unconfined。事实并非如此,因为这两个项目在docker run命令中都已经有了这个功能
Docker运行命令:
docker run --security-opt=seccomp:unconfined --rm --net="host" -e LOGGER_LEVEL='error' -v `pwd`:/go/src/github.com/marcosvpj/rey -w /go/src/github.com/marcosvpj/rey rey ./hack/check.sh
如何将项目添加到容器中?您绑定挂载它了吗?您能给出您正在使用的
docker run
命令吗?@SeanKelleher添加了该命令