Search code examples
gitpermissionsdirectorygitolite

how to restrict read permisson to some directories,while somes are with no read permission in gitolite?


git version is 1.7.0.4.
My repository tree is like below,

reponame
--------code
------------sevenEleven
------------out

I need to limit sevenEleven read permission only to mary, and out read permission only to jack.
I tried following setting, but failed.
For mary, she can read both code and sevenEleven directory.

R                 =  mary
R  NAME/code/out/ =mary

Does anyone can help me ?


Solution

  • Gitolite cannot restrict "read" access for a part of the repo, only write access.

    Read access are for a all repo, for clone or fetch operations.

    See "applying deny rules during the first check"

    The VREF NAME is only there to prevent write (modification or push) for files and directory, not read access.

    A true read access would be by having sevenEleven and out in their own git repos.