Skip to content

Commit

Permalink
chore(compose): Don't mount GOPATH if not used.
Browse files Browse the repository at this point in the history
  • Loading branch information
danielmai authored and aman-bansal committed Apr 7, 2021
1 parent 7c1184b commit d161f53
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions compose/compose.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,12 +175,14 @@ func initService(basename string, idx, grpcPort int) service {
toPort(grpcPort + 1000), // http port
}

svc.Volumes = append(svc.Volumes, volume{
Type: "bind",
Source: "$GOPATH/bin",
Target: "/gobin",
ReadOnly: true,
})
if opts.LocalBin {
svc.Volumes = append(svc.Volumes, volume{
Type: "bind",
Source: "$GOPATH/bin",
Target: "/gobin",
ReadOnly: true,
})
}

switch {
case opts.DataVol:
Expand Down

0 comments on commit d161f53

Please sign in to comment.