Thursday, June 13, 2024
HomeGolangGo get obtain personal venture of personal gitlab failed - Getting Assist

Go get obtain personal venture of personal gitlab failed – Getting Assist


I’ve a venture that should depend on the personal venture of personal gitlab.

I configured it by way of the next command, however a URL 404 error occurred. The instance is as follows

$ go env -w GOPRIVATE=a.b.com
$ go env -w GOINSECURE=a.b.com
$ go env -w GONOPROXY=a.b.com
$ git config --global url."https://username:private-token@a.b.com".insteadOf "http://a.b.com"
$ go get -v -x a.b.com/testgroup/compkg
# get https://a.b.com/?go-get=1
# get https://a.b.com/testgroup/testpkg?go-get=1
# get https://a.b.com/testgroup?go-get=1
# get https://a.b.com/testgroup?go-get=1: 404 Not Discovered (0.044s)
# get https://a.b.com/?go-get=1: 403 Forbidden (0.044s)
# get https://a.b.com/testgroup/testpkg?go-get=1: 404 Not Discovered (0.044s)
# get https://a.b.com/testgroup/testpkg?go-get=1
# get https://a.b.com/testgroup?go-get=1
# get https://a.b.com/?go-get=1
# get https://a.b.com/testgroup/testpkg?go-get=1: 404 Not Discovered (0.001s)
# get https://a.b.com/testgroup?go-get=1: 404 Not Discovered (0.001s)
# get https://a.b.com/?go-get=1: 403 Forbidden (0.002s)
go get: unrecognized import path "a.b.com/testgroup/testpkg": studying https://a.b.com/testgroup/testpkg?go-get=1: 404 Not Discovered

Then I attempted to modify to ssh to tug, the instance is as follows

$ git config --global url."git@a.b.com:testgroup/compkg.git".insteadOf "https://a.b.com/testgroup/compkg"
$ go get -v -x a.b.com/testgroup/compkg
# get https://a.b.com/?go-get=1
# get https://a.b.com/testgroup/testpkg?go-get=1
# get https://a.b.com/testgroup?go-get=1
# get https://a.b.com/testgroup?go-get=1: 404 Not Discovered (0.044s)
# get https://a.b.com/?go-get=1: 403 Forbidden (0.044s)
# get https://a.b.com/testgroup/testpkg?go-get=1: 404 Not Discovered (0.044s)
# get https://a.b.com/testgroup/testpkg?go-get=1
# get https://a.b.com/testgroup?go-get=1
# get https://a.b.com/?go-get=1
# get https://a.b.com/testgroup/testpkg?go-get=1: 404 Not Discovered (0.001s)
# get https://a.b.com/testgroup?go-get=1: 404 Not Discovered (0.001s)
# get https://a.b.com/?go-get=1: 403 Forbidden (0.002s)
go get: unrecognized import path "a.b.com/testgroup/testpkg": studying https://a.b.com/testgroup/testpkg?go-get=1: 404 Not Discovered

Similar error on each makes an attempt. go get: unrecognize import path "a.b.com/testgroup/compkg": studying https://a.b.com/testgroup/compkg?go-get=1: 404 Not Discovered

Is there some other option to strive, or is it my trial and error? Wanting ahead to your reply.

PS: testgroup is groupname not username of gitlab.

  • gitlab model: Gitlab Group Version 13.6.7
  • go model: go v1.16 and v1.20
  • I can git clone venture by enter username and password

Your GOPRIVATE env appears appropriate to me. I’ve used that earlier than with personal modules and it labored OK however I’m not tremendous skilled with personal modules or something. Perhaps observe this information?

Sadly, I attempted following the hyperlink and altered the tackle to mine, however the error continues to be there.

I don’t know whether it is as a result of I take advantage of the gitlab group slightly than the consumer title. gitlab.firm.com/group/reponame as an alternative of gitlab.firm.com/myusername/reponame

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments