Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Gitlab 6.2 asking for username and password authentication when pushing to origin

Tags:

git

http

gitlab

I'm running GitLab 6.2 on a Linux Debian box and it looks like I can't push to the remote repository from the command line.

Every time I do a

git push -u origin master

it asks for the username and password (I've added the origin as an HTTP remote)

like image 837
Valerio Santinelli Avatar asked Nov 11 '13 12:11

Valerio Santinelli


1 Answers

Check that your remotes aren't set to use http/https:

$ git remote -v
origin  https://somedomain.com/username/repo.git (fetch)
origin  https://somedomain.com/username/repo.git (push)

If it looks like the above, try switching to using ssh like so:

$ git remote rm origin
$ git remote add origin [email protected]:username/repo.git
like image 102
JBarberU Avatar answered Nov 13 '22 18:11

JBarberU