Installation inside Docker #75
-
When tried to install inside a docker container via dockerfile, it was noticed that the go.mod and go.sum were not available and hence an error - no required module provides package github.com/carlmjohnson/requests: go.mod file not found in current directory or any parent directory; see 'go help modules' - was found. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
This is really a Docker question, not a requests question. You'll have the same problem with any Go module. The "right" way to build a Docker image is a big topic, but the basic answer is there in the error message: you need to use COPY to copy go.mod and go.sum from your system into the Docker image to have it work. |
Beta Was this translation helpful? Give feedback.
This is really a Docker question, not a requests question. You'll have the same problem with any Go module. The "right" way to build a Docker image is a big topic, but the basic answer is there in the error message: you need to use COPY to copy go.mod and go.sum from your system into the Docker image to have it work.