I am building a go app inside a docker container
When I try to run a docker container inside Golang with this command preview
docker build -f Dockerfile.local -t myGoApp:exp . && docker run -v /volume:/go --name myGoApp --env-file ./test.env --network=myGoApp_network myGoApp:exp
I get:
Building image...
Failed to deploy 'myGoApp Dockerfile: Dockerfile.local': com.github.dockerjava.api.exception.DockerClientException: Error occurred while preparing Docker context folder.<br/>caused by: java.io.FileNotFoundException: /home/julien/go/src/gitlab.com/xxx/myGoApp/vendor/github.com/influxdata/platform/chronograf/.eslintrc (No such file or directory)
When I run the same command on a terminal, it works
When I run the equivalent inside a docker compose via Goland, it also works.
I also checked, and the .eslintrc
in question exists.
Why is it happening ? Googling, I could find that it has to do with docker-java, but I could not really find a way to solution.
Here is docker version info:
Client:
Version: 18.09.1
API version: 1.39
Go version: go1.10.6
Git commit: 4c52b90
Built: Wed Jan 9 19:35:31 2019
OS/Arch: linux/amd64
Experimental: false
Server: Docker Engine - Community
Engine:
Version: 18.09.1
API version: 1.39 (minimum version 1.12)
Go version: go1.10.6
Git commit: 4c52b90
Built: Wed Jan 9 19:02:44 2019
OS/Arch: linux/amd64
Experimental: false
Any idea what's wrong ? I need to launch it that way because I want to implement debugging inside a container like explained here