gerrit: access gerrit repositories as root user by using public key of another user
We are using Active Directory for gerrit authentication and added our ssh-public keys to access git repos. If we use usernames same as AD users in linux boxes we are able to work well. But some of our work requires to use root user in linux boxes so we want to use root user completely to clone git repos and push changes to gerrit. But when we try to clone git repos from root user we are getting below error message git clone ssh://gerrit.doamin.com:29418/gitrepo.git Cloning into 'girepo... Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists I have copied existing gerit user's ssh-key pair to /root/.ssh but still I am facing same issue. Is it possible to access git repos in gerrit as root by copying public keys of another gerrit user?
I got an answer from gerrit google groups community. Thanks to "David Ostrovsky" Adding an ssh alias in /root/.ssh/config and use it in clone command: Host gerrit HostName <gerrit server> User joe Port 29418
setup AOSP source on local gerrit
How do I give people rights in gerrit to see other people's rights
gerrit query doesn't print PL
How to prevent gerrit push to authoritative repository
what is the use refs/for/refs/* in gerrit?
How to put a local repo project into gerrit?
What is the effect of deleting a branch in gerrit
Right way to resolve gerrit “pending changes” merge conflict
Buck build failing for “events-logs” Gerrit plugin (jar)
Disable direct push and allow Gerrit push
Set “topic” of multiple patches simultaneously in gerrit
Using Gerrit to restrict read access to a git branch
Is it possible to search for commit by Change-Id in Gerrit?
Why is the gerrit change-id commit-hook not a push-hook?
LDAP changed acccount Full Name is not displaying in gerrit web page