Steps to reproduce
- Install Go 1.14
- Create a private organisation in Gitlab
- Create a private subgroup in the organisation
- Create a private repository in the subgroup
- Clone the repository locally
- cd to the repository
- Initialise new go module
go mod init gitlab.com/myorganisation/mysubgroup/myrepository
- Commit and push
- cd to another go modules enabled repository
- Run
go get gitlab.com/myorganisation/mysubgroup/myrepository
Got error:
go get gitlab.com/myorganisation/mysubgroup/repo1: git ls-remote -q https://gitlab.com/myorganisation/mysubgroup.git in /Volumes/CS/go/pkg/mod/cache/vcs/a96c83d4d1395bc931a1a8ac402e8d8e494cc85efa9081cab02316963aa836ed: exit status 128:
The project you were looking for could not be found.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.