To use svnserve daemon a user and group must be created. The group can be auto created with WITH_REPOSITORY_CREATION however no user is created. I have attached a patch that also creates the user in the same way the group is already created. Also, the svnserve daemon's rc script defaults the path to %%PREFIX%%/repositories where as the Makefile (for the purposes of WITH_REPOSITORY_CREATION) defaults to /home/svn/repos. One of these should be changed. The second attached patch changes the RC script to /home/svn/repos Fix: Patch for makefile (not heavily tested) ------------------- drs# diff -u Makefile.old Makefile .if defined(WITH_APACHE2_APR) @@ -300,10 +302,10 @@ .endif @${ECHO_MSG} "" .if defined(WITH_REPOSITORY_CREATION) - @${ECHO_MSG} "I will create (or use, if it exists) \"${SVNGROUP}\" group." + @${ECHO_MSG} "I will create (or use, if it exists) \"${SVNUSER}\" user and \"${SVNGROUP}\" group." @${ECHO_MSG} "Make sure that all committers are its members." @${ECHO_MSG} "" - @${ECHO_MSG} "Repository will be created at '${SVNREPOS}' with group '${SVNGROUP}'." + @${ECHO_MSG} "Repository will be created at '${SVNREPOS}' with user \"${SVNUSER}\" and group '${SVNGROUP}'." @${ECHO_MSG} "Type of repository will be '${SVNFSTYPE}'." @${ECHO_MSG} "You could change these settings by defining SVNREPOS, SVNGROUP and SVNFSTYPE." .else @@ -449,17 +451,29 @@ ${FALSE}; \ fi; \ fi + @if /usr/sbin/pw usershow "${SVNUSER}" >/dev/null 2>&1; then \ + ${ECHO_MSG} "You already have a user \"${SVNUSER}\", so I will use it."; \ + else \ + if /usr/sbin/pw useradd ${SVNUSER} -h -; \ + then \ + ${ECHO_MSG} "Added user \"${SVNUSER}\"."; \ + else \ + ${ECHO_MSG} "Adding user \"${SVNUSER}\" failed..."; \ + ${ECHO_MSG} "Please create it, and try again."; \ + ${FALSE}; \ + fi; \ + .endif @${MKDIR} ${SVNREPOS} @${PREFIX}/bin/svnadmin create --fs-type ${SVNFSTYPE} ${SVNREPOS} .if defined(WITH_SVNSERVE_WRAPPER) - @${CHGRP} ${SVNGROUP} ${SVNGRPFILES} + @${CHOWN} ${SVNUSER}:${SVNGROUP} ${SVNGRPFILES} @${CHMOD} g+w ${SVNGRPFILES} @for i in ${SVNREPOS}/db/* ; do \ i=$${i##*/}; \ case $$i in \ DB_CONFIG|fs-type|uuid) ;; \ - *) ${CHGRP} -R ${SVNGROUP} ${SVNREPOS}/{SVNREPOS}/db/$$i; \ ${CHMOD} -R g+w ${SVNREPOS}/db/$$i; \ ;; \ esac; \ Second patch ------------ drs# diff -u svnserve.in.old svnserve.in
Responsible Changed From-To: freebsd-ports-bugs->lev Over to maintainer (via the GNATS Auto Assign Tool)
lev 2008-10-25 09:06:21 UTC FreeBSD ports repository Modified files: devel/subversion Makefile Makefile.common distinfo devel/subversion/files build-outputs.mk svnserve.in Log: (1) Update to 1.5.4 (2) Create SVNUSER in cases when SVHGROUP is created [1] (3) Change default repository path to "/home/svn/repos" in svnwrapper [1] (4) Fix typo [2] PR: [1] ports/122972, [2] ports/127347 Revision Changes Path 1.124 +17 -5 ports/devel/subversion/Makefile 1.10 +4 -2 ports/devel/subversion/Makefile.common 1.59 +3 -9 ports/devel/subversion/distinfo 1.3 +42 -42 ports/devel/subversion/files/build-outputs.mk 1.2 +1 -1 ports/devel/subversion/files/svnserve.in _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: open->closed Committed, thanks!