Gitolite
Installation
Package: gitolite
useradd -m projects
ssh-keygen -t rsa -b 2048 -N "nopassword" -f /tmp/id_rsa
Notice: Optional if you have already public key.
dpkg-reconfigure gitolite
Note: this command allow also to create a new repositories directory.
Configuration
.gitolite.rc
$REPO_UMASK = 0077; # gets you 'rwx------'
gitolite.conf
repo test1
RW+ = @admin
- master = @dev
RW = @dev
# source: https://groups.google.com/g/gitolite/c/d2M8Aks_aAw
repo test2
RW master = @admin
RW+ [^m][^a][^s][^t][^e][^r] = @admin
Notes:
admin
group can do anything ontest1
, but cannot rewind/rebase on other branches thanmaster
ontest2
dev
group can do nothing on branchmaster
oftest1
, but can create any other branches ontest1
, except rebase/rewind on these other branches