[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: Empty output of svn update in hook script

From: Borek Bernard <borekb_at_gmail.com>
Date: Wed, 10 Jun 2009 17:23:33 +0200

Indeed, changing Apache user from Local System to WhateverUserWeUse fixed it. Weird is that the script worked on one of our other servers, just not on the production one, even though the folder has R/W permissions for "Everyone".

Thanks,
Borek

-----Original Message-----
From: Andy Levy [mailto:andy.levy_at_gmail.com]
Sent: Wednesday, June 10, 2009 5:21 PM
To: Borek Bernard
Cc: users_at_subversion.tigris.org
Subject: Re: Empty output of svn update in hook script

On 2009-06-10, Borek Bernard <borekb_at_gmail.com> wrote:
> I'm running Apache 2.2 server (Windows) with SVN 1.6.2 and want to update my production server after each commit. Therefore, I've set up a post-commit hook like this:
>
>
> svn update \\myserver\livefolder
> exit 0
>
>
> When I execute this post-commit.bat script on command line, it works fine. However, when the hook script gets executed by Apache, my production server isn't updated. To help debug the issue, this is how I amended the script:
>
>
> echo %time% > mylog.txt
> svn update \\myserver\livefolder
> exit 0
>
>
> Normally, in mylog.txt file, I should see something like
>
>
> 13:44:11.91
> U \\wendy\wendyd\worddocs\temp.txt
> Updated to revision 35.
>
>
> which I indeed do when the script is run from the command line but when I run it via the commit operation, I can see only the timestamp. Isn't it weird that the svn update doesn't output anything? Not even "updated to revision XYZ"? At the same time, I think the command doesn't crash because all the subsequent lines (if there are any) are executed just fine.
>
> Even more curiously, when I add some other server like \\testserver\testlocation to the script (after the failing production server), it gets updated fine.

The user account Apache is running under doesn't have the appropriate
permissions on the UNC path you're attempting to update. When you log
in and run it, it's using your credentials, not Apache's.

Doing things like this across different servers can get tricky.

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2360954

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-06-10 17:24:33 CEST

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.