At work I got a new task. First I thought, no problem I can
do this in few minutes. But then when trying to implement it,
I needed nearly 2 hours.
The problem!
You have a group of 20 or more developers accessing a corporate
subversion server. All developers are in a Active Directory managed
group and have read-write access. Now a single person should get
read-only access to the repository.
How I manage it?
As the internal authz_svn Apache authorization module does not
support to overwrite rw rights with just r rights, you can
not use it. Tried different combinations without success.
The only possibility would be to generate a new group in the
access list file, but then I would need to sync it with Active Directory.
The solution:
After a short discussion with a colleague, I got an idea.
I remount the SVN repository to a new directory via bind mount.
mkdir /var/svn-ro
mount -o bind /var/svn /var/svn-ro
mount -o remount,ro /var/svn-ro
You need to add it to /etc/fstab and the remount call
to /etc/rc.local. It is not possible to express this in a single
fstab line.
After that I exported this repository with just the single user
in a special Active Directory group. And voila, everything is fine now.
Happy coding,
Waldemar
Saturday, April 25. 2015
Managing read-only subversion repository for an single user
Trackbacks
Trackback specific URI for this entry
No Trackbacks