Skip to content
Advertisement

Password for GitLab

I’ve installed GitLab per https://github.com/gitlabhq/gitlab-recipes/tree/master/install/centos.

The instructions state to add user “git”

JavaScript

All seemed to work. I then added a project on the GitLab server, and it gave instructions to push to it:

JavaScript

I then went to my client to push to the git server.

JavaScript

Is there a password I should have set? Probably not, and instructions don’t address.

Reading System ask password when push project to github, it appears it might be related to SSH.

GitLab provides the following instructions to add a SSH key. I followed them, and first added the key to my general user’s home on the server. No change. Then tried logging on a root, and added a key to git’s home. Still none, but I am thinking that the client already has my general user’s key, thus is not pulling the new git key.

EDIT. Please confirm that I should add these keys to the GitLab server, and not my Linux client.

Any and all help would be very much appreciated.

JavaScript

EDIT 2

Looks like I was confused, and used GitLab’s server id_rsa.pub. Guess that doesn’t make any sense! I’ve since corrected it, but now I get this error:

JavaScript

Advertisement

Answer

Seems like a SELinux permission issue. Steps to follow:

  1. restorecon -R -v /home/git/.ssh
  2. usermod -s /bin/bash git
  3. Edit your home machine user’s .ssh/config to something like:
JavaScript

Try connecting to the gitlab server ssh -T git@mysite.com. You should see a message welcoming you.

I added it to the installation guide. I have a merge request ready with several enhancements. I will merge it when gitlab 6.8 is released.

User contributions licensed under: CC BY-SA
9 People found this is helpful
Advertisement