![]() ![]() To give control to Gitolite if a user connects and to tell it which user it is.Īnd that this sudo command works without password you do visudo and there in the sudoers file add Defaults!/opt/gitolite/src/gitolite-shell env_keep+=SSH_CONNECTIONĭefaults!/opt/gitolite/src/gitolite-shell env_keep+=SSH_ORIGINAL_COMMAND In /etc/ssh/sshd_config you would have Match Group git-usersįorceCommand sudo -u git -H /opt/gitolite/src/gitolite-shell $USER IF anything is not true, just adapt the instructions For my example I assume you stuff all git users into the group git-users, the hostname is git, Gitolite is operating as user git and Gitolite is installed at /opt/gitolite. If you want password authentication via SSH and authorization via Gitolite, you can easily do this.īasically what you do is, you create an account for each user and put them in a group, or you apply the following Match to all users and make exceptions for ones that should be able to actually log in. Warning a "shared repository" is not what you think from the name.There are non-bare repositories, you must read up on this, use the standard Git references, just Google.when you have used git add and git commit, then you can use git push to push commits to the central repo. To clone a repo: $ git clone :/var/git/myreponame.git To clone it to your desktop Debian or Ubuntu:įor SSH connections: look up ssh keygen and set up a passwordless connection to your server- keygen and sharing is only two commands. So to make a git repo on a Debian or Ubuntu server for centralized use: # apt-get install gitĪt this point you have an empty repo. Generally speaking, Git depends on the server's authentication. You can still have a central repository in Git, and if you do, your users will need to be able to log into that server using SSH or HTTP access, look it up. Perhaps you aren't aware of this, but Git is a distributed VCS. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |