-
Notifications
You must be signed in to change notification settings - Fork 279
Using with go mod #138
Comments
I don't think any extra options to xgo are needed. xgo can determine whether the package to be built is inside GOPATH or not and reproduce that setup in the container. |
Is that currently working? So, if I mount it to somewhere outside of |
It's not currently working, it's a proposal. |
Need add Build flags "-mod=vendor" |
@zaaksam Do you think it should also try to autodetect that and build accordingly? (aka look for a vendor folder and go.mod and the use the vendor folder) Or only use an extra flag to explicitly enable it? |
I've hacked a pr together: #144 |
The PR I sent to @kolaente ( |
@zgramana so does this actually work now? (I was wondering because the PR seems to be merged while this issue is still open) 🤔 |
This was merged into @kolaente’s fork. Given that they are actively maintaining theirs, I recommend you use theirs instead: https://github.com/techknowlogick/xgo. |
Is it possible to use
xgo
with go modules? When using the latest version of xgo, it doesn't use the modules, I get an error likeIMHO there are two possibilites to solve this: Either add an option to xgo which allows specifying extra evironment variables which are then passed to the container or an extra parameter to enable go modules (which would also pass an environment variable to the container).
The text was updated successfully, but these errors were encountered: