Hello all, now I am completely lost. Out of an curiosity I have removed the build command from my Dockerfile and created an image with just my code in it, started an interactive shell session in the container and issued the build command .. Guess what happend, it built my software ..
``` % docker run --rm -it foo:latest bash root@bb681679869b:/go/asm# ls Dockerfile Makefile README.md cmd config.yaml examples go.mod go.sum pkg root@bb681679869b:/go/asm# cd cmd/asm/ root@bb681679869b:/go/asm/cmd/asm# ls main.go root@bb681679869b:/go/asm/cmd/asm# go build go: finding github.com/kr/pretty v0.1.0 go: finding github.com/stretchr/testify v1.3.0 go: finding github.com/aws/aws-sdk-go v1.19.5 go: finding golang.org/x/net v0.0.0-20190327091125-710a502c58a2 go: finding gopkg.in/yaml.v2 v2.2.2 go: finding github.com/kr/text v0.1.0 go: finding github.com/stretchr/objx v0.1.0 go: finding github.com/pmezard/go-difflib v1.0.0 go: finding github.com/davecgh/go-spew v1.1.0 go: finding gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 go: finding github.com/kr/pty v1.1.1 go: finding golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 go: finding golang.org/x/text v0.3.0 go: finding golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a go: finding github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af go: downloading gopkg.in/yaml.v2 v2.2.2 go: downloading github.com/aws/aws-sdk-go v1.19.5 go: downloading github.com/kr/pretty v0.1.0 go: extracting github.com/kr/pretty v0.1.0 go: downloading github.com/kr/text v0.1.0 go: extracting github.com/kr/text v0.1.0 go: extracting gopkg.in/yaml.v2 v2.2.2 go: extracting github.com/aws/aws-sdk-go v1.19.5 go: downloading github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af go: extracting github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af root@bb681679869b:/go/asm/cmd/asm# ls -la total 10428 drwxr-xr-x 1 501 dialout 4096 Apr 3 10:19 . drwxr-xr-x 1 501 dialout 4096 Apr 2 08:30 .. -rwxr-xr-x 1 root root 10663945 Apr 3 10:19 asm -rw-r--r-- 1 501 dialout 3068 Apr 2 14:11 main.go ``` Why does the interactive shell is able to compile, while the one from the formerly pasted RUN go build .. from my Dockerfile does not? Is this a bug? Even more puzzled regards, Marcus > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
