Subversion : Set Access Control2015/07/13 |
Set Access Control on repositories for the case svnserve is running.
|
|
[1] | For example, Set Access Control on "/var/svn/repos/project". |
[root@dlp ~]#
vi /var/svn/repos/project/conf/svnserve.conf # line 9: add (prohibit anonymous access) [general]
anon-access = none
# line 28: uncomment password-db = passwd # line 35: uncomment authz-db = authz
[root@dlp ~]#
vi /var/svn/repos/project/conf/passwd # define username and password for this repository [users]
redhat = password
cent = password fedora = password
[root@dlp ~]#
vi /var/svn/repos/project/conf/authz # define groups and users [groups]
developer = redhat,cent
# allow read/write on document root for developer group [/] @developer = rw # allow read on trunk folder for fedora user [/trunk] fedora = r |
[2] | Make sure to access from a client. |
[cent@client trunk]$ svn --username redhat commit -m "update" Authentication realm: <svn://dlp.srv.world:3690> fd349a1d-65a8-441f-a9e5-907abc1b6c19 Password for 'redhat':Store password unencrypted (yes/no)? no Sending trunk/count.cgi Transmitting file data . Committed revision 5.[cent@client ~]$ svn --username fedora list svn://dlp.srv.world/repos/project/trunk Authentication realm: <svn://dlp.srv.world:3690> fd349a1d-65a8-441f-a9e5-907abc1b6c19 Password for 'fedora':Store password unencrypted (yes/no)? no count.cgi index.html main.php |
Sponsored Link |