<div class="gmail_quote">2009/7/22 Aaron Gray <span dir="ltr"><<a href="mailto:aaronngray.lists@googlemail.com">aaronngray.lists@googlemail.com</a>></span><br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div class="gmail_quote">2009/7/22 Todd Zullinger <span dir="ltr"><<a href="mailto:tmz@pobox.com" target="_blank">tmz@pobox.com</a>></span> 
<div class="im"><br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div>I wrote:<br>> It depends on how fine-grained you want things.  If all the users have<br>> ssh accounts on the system, you can just make the repository shared<br>> and add everyone who should have commit privileges to the group used<br>

> for the repository.  This is how it is done on <a href="http://fedorahosted.org/" target="_blank">fedorahosted.org</a>.  For<br>> example, if your git repo is at /git/repo.git:<br>><br>>     # Tell git the repository is shared<br>

>     $ git --git-dir /git/repo.git config core.sharedrepository true<br>><br>>     # Set proper group ownership<br>>     $ chgrp -R gitgroup /git/repo.git<br>><br>>     # Make all directories setgid<br>

>     $ find /git/repo.git -type d -exec chmod g+s {} \;<br>><br>>     # Ensure files and dirs are group writable<br>>     $ find /git/repo.git/ \( -type f -o -type d \) -a \<br>>                           \( -perm /u+w -a ! -perm /g+w \) \<br>

>         xargs chmod g+w<br><br></div>Incidentally, most of this is only needed if you're dealing with a<br>repository that you've already created.  If you're initializing a new<br>repo you can skip most of it.<br>

<br>   $ git --git-dir /git/repo.git --bare init --shared=true<br>
<div>   $ chgrp -R gitgroup /git/repo.git<br><br></div>Then you can easily push things into it from an existing repo to add<br>content and git will handle the permissions.</blockquote>
<div> </div></div>
<div>Yes pushing over SSH is working great now, thanks. Just groups to sort out.</div>
<div></div></div></blockquote>
<div> </div>
<div> </div>
<div>I have set '/pub/git/expermental' to 'git:gitgroup'</div>
<div> </div>
<div>and added 'gitgroup' as a group to 'ang'</div>
<div> </div>
<div>remotely this fails :-</div>
<div> </div>
<div><a href="mailto:ang@AMD2500-PC"><font face="courier new,monospace">ang@AMD2500-PC</font></a><font face="courier new,monospace"> ~/git/experimental<br>$ git push ssh://<a href="http://git.cybercomms.org/pub/git/experimental/.git">git.cybercomms.org/pub/git/experimental/.git</a><br>

</font><a href="mailto:ang@git.cybercomms.org's"><font face="courier new,monospace">ang@git.cybercomms.org's</font></a><font face="courier new,monospace"> password:<br>Counting objects: 3, done.<br>Compressing objects: 100% (2/2), done.<br>

Writing objects: 100% (2/2), 234 bytes, done.<br>Total 2 (delta 1), reused 0 (delta 0)<br>error: insufficient permission for adding an object to repository database ./obj<br>ects</font></div>
<div><font face="courier new,monospace">fatal: failed to write object<br>error: unpack failed: unpacker exited with error code<br>To ssh://<a href="http://git.cybercomms.org/pub/git/experimental/.git">git.cybercomms.org/pub/git/experimental/.git</a><br>

 ! [remote rejected] master -> master (n/a (unpacker error))<br>error: failed to push some refs to 'ssh://<a href="http://git.cybercomms.org/pub/git/experimenta">git.cybercomms.org/pub/git/experimenta</a><br>l/.git'<br>

</font></div>
<div>But if I set ''/pub/git/expermental' to 'ang:ang' then it works.</div>
<div> </div>
<div>Help, stuck again !</div>
<div> </div>
<div>Aaron</div>
<div> </div>
<div> </div></div>