git clone/push via ssh fails with password prompt for specific user
Created by: moses-rolston
git clone/push via ssh fails for user "jira", but only for that user. I had a previous installation that worked fine with that user, same version of gitlab even.
steps to re-create the issue (seems specific to my install): add user jira as jira add ssh key via web interface on remote system git clone [email protected]:jira/jira.git receive password prompt
steps to resolve: delete key through web interface. then add key through web interface delete user jira, create user jira, add key delete key, delete user jira, add user jira, add key delete key, delete user jira, restart gitlab, add user jira, add key delete key, delete user jira, restart gitlab, generate new keypair for jira, add key
the entry in authorized_keys is appropriatly made. after removing the gitlab specific info from the line a diff of id_rsa.pub and the authorized key entry is identical.
entry in gitlabs authorized_keys file
command="/home/git/gitlab-shell/bin/gitlab-shell key-10",no-port-forwarding,no-X11-forwarding,no-agent-forwarding,no-pty ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDROFHKw8NLHcdGc4KefsekUNy5JYnriREz7jEX2ZLRuSPerS/mr0Ri4BJ0Np5sp38J53rG/B9ByA4YazGQwhz1dd+zwxo0qb0CFNkE9JxbOmz3RCtgEM/m9gcVXJfaTl2XW8KNmAFCScv4ZQhfOxrLDj0H33VUSaQyMnvg7pkilFYMO3f3wS3fxwadkTVwuAguOAdiF+3gDYNkJxWMqM3Q9cO74R2lxcc9kQ0isGsgJSTpiV0XdXxXl1LbsQQFSr8qPHOFrjT0o7VoHDjZgOboXQSKWG8lOEKRBqjcBY5qIVAvjl4wPQm4YvedncaBr+92p7gCt5ec3F7mLg0tktzn jira@jira
running the gitlab check script returns git@gitlab:~/gitlab$ bundle exec rake gitlab:check RAILS_ENV=production Checking Environment ...
Git configured for git user? ... yes Has python2? ... yes python2 is supported version? ... yes
Checking Environment ... Finished
Checking GitLab Shell ...
GitLab Shell version >= 1.7.0 ? ... OK (1.7.1) Repo base directory exists? ... yes Repo base directory is a symlink? ... no Repo base owned by git:git? ... yes Repo base access is drwxrws---? ... yes post-receive hook up-to-date? ... can't check because of previous errors post-receive hooks in repos are links: ... can't check because of previous errors
Checking GitLab Shell ... Finished
Checking Sidekiq ...
Running? ... yes
Checking Sidekiq ... Finished
Checking GitLab ...
Database config exists? ... yes Database is SQLite ... no All migrations up? ... yes GitLab config exists? ... yes GitLab config outdated? ... no Log directory writable? ... yes Tmp directory writable? ... yes Init script exists? ... yes Init script up-to-date? ... yes Projects have satellites? ... West Coast Container / Server Configs ... yes Moses Rolston / Kameosa ... yes Lab6ix / brewIQ ... yes Lab6ix / Emerge ... yes jira / jira ... can't create, repository is empty West Coast Container / splinner ... yes Moses Rolston / moses_personal ... can't create, repository is empty Lab6ix / lab6ix_site ... yes Redis version >= 2.0.0? ... yes Your git bin path is "/usr/bin/git" Git version >= 1.7.10 ? ... no Try fixing it: Update your git to a version >= 1.7.10 from 1.7.9 Please fix the error above and rerun the checks.
Checking GitLab ... Finished