1

I've got a private gitlab server configured for ssh on port 2222

My golang project are using glide for dependency management, sometimes importing other project from the private server

The URL of my projects looks something like this:

ssh://git@gitlab.myserver.com:2222/group/project.git

My import lines in go look something like this:

import gitlab.myserver.com/group/project/package

I know I can set the exact repo URL in glide.yaml, but I would like to configure the machine to use the correct address instead.

I've read you can use command like this:

git config --global url."..." insteadOf.".."

I'm not sure how to use that though. I've also seen that you can configure ssh (~/.ssh/config) to redirect to the correct URL.

I haven't manage to make it work yet. How can I do that?

Zoe
  • 27,060
  • 21
  • 118
  • 148
BlueMagma
  • 2,392
  • 1
  • 22
  • 46
  • Which approach do you want help with? You've offered three different solutions, all of which are legitimate. – Jonathan Hall May 02 '18 at 17:14
  • I want to avoid having to set it in glide.yaml, but the other two method are not working for me, I'm assuming I did it incorrectly – BlueMagma May 03 '18 at 09:08

0 Answers0