{"thread":{"id":"12249","subject":"Re: Object Permissions - trying git-init --shared=group parameters","startedAt":"2008-02-21T22:06:39Z","lastAt":"2008-02-21T22:16:04Z","messageCount":2,"participants":["Pete/Piet Delaney","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"69527","messageId":"47BDF5EF.9030707@bluelane.com","threadId":"12249","inReplyTo":null,"subject":"Re: Object Permissions - trying git-init --shared=group parameters","fromName":"Pete/Piet Delaney","fromEmail":"pete@bluelane.com","sentAt":"2008-02-21T22:06:39Z","receivedAt":"2008-02-21T22:06:39Z","isPatch":false,"sender":{"key":"pete@bluelane.com","avatar":null},"body":"-----BEGIN PGP SIGNED MESSAGE-----\nHash: SHA1\n\nJunio C Hamano wrote:\n| Pete/Piet Delaney <pete@bluelane.com> writes:\n|\n|> I've been trying to us the git repo in a\n|> centralize pull, push model where the\n|> developers pull the repo, checkout a\n|> branch, commit and then push back to the\n|> common repo.\n|>\n|> Problem is that the objects get set with\n|> the ownership of the user (at least when\n|> pulling with this format:\n|>\n|> ~    git clone git:/home/git/blux\n|>\n|> Amy suggestions on how to do this?\n|\n| \"man git-config\" and look for core.sharedrepository, perhaps?\n\nThat's kinda what I'm trying. I did a git-init --shared=group\nand found that it set:\n\n\n\t[core]\n~        \trepositoryformatversion = 0\n~        \tfilemode = true\n~        \tbare = false\n~        \tlogallrefupdates = true\n~        \tsharedrepository = 1\n\n\t[receive]\n~        \tdenyNonFastforwards = true\n\nSo I looked int the meaning of these config prams and\nthought I tried adding:\n\n\tsharedrepository = 1\n\n\tdenyNonFastforwards = true\n\nto the bare repo on the git server. I'm not sure if\nexisting repo that have been cloned will have to be\nupdated, hopefully not.\n\n- -piet\n\n-----BEGIN PGP SIGNATURE-----\nVersion: GnuPG v1.4.7 (GNU/Linux)\nComment: Using GnuPG with Mozilla - http://enigmail.mozdev.org\n\niD8DBQFHvfXuJICwm/rv3hoRAl+PAJ9M/dRAuWRjs8gUvq1w3JqeH8/tNgCdFbto\niaqrDyOefH4zTEK8Zzximu4=\n=xJM3\n-----END PGP SIGNATURE-----\n"},{"id":"69528","messageId":"7vzlturm57.fsf@gitster.siamese.dyndns.org","threadId":"12249","inReplyTo":"47BDF5EF.9030707@bluelane.com","subject":"Re: Object Permissions - trying git-init --shared=group parameters","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2008-02-21T22:16:04Z","receivedAt":"2008-02-21T22:16:04Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Pete/Piet Delaney <pete@bluelane.com> writes:\n\n> So I looked int the meaning of these config prams and\n> thought I tried adding:\n>\n> \tsharedrepository = 1\n>\n> \tdenyNonFastforwards = true\n>\n> to the bare repo on the git server. I'm not sure if\n> existing repo that have been cloned will have to be\n> updated, hopefully not.\n\nYou would at least make sure the directories there that was\ncreated while the repository was misconfigured can be writable\nby group members (i.e. permissions no stricter than drwxrws---)\nand owned by the group.  Something like\n\n\tmode=2775 ;# 2770 if closed to non-members\n\tchgrp -R $group $GIT_DIR\n\tfind $GIT_DIR -type d -print0 | xargs -0 chmod $mode\n"}]}