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

Re: execute java jar file in a post-commit hook

From: Daniel Rall <dlr_at_collab.net>
Date: 2006-12-05 21:16:14 CET

On Tue, 05 Dec 2006, kkrikor wrote:

>
> Does this work ? I placed the following code in post-commit
> Code:
>
>
> # Trigger a build everytime a commit happens
> /usr/local/java/bin/java -jar
> /home/x/triggerContBuild/target/triggerContBuild/trigger/triggerContBuild.jar
>
> # Send an email everytime a commit happens
> /var/www/svnroot/hooks/commit-email.pl --from x@x.com "$REPOS" "$REV"
> x@x.com
>
>
>
> When i execute this post-commit on the command the jar file runs , But when
> i do a commit i get the email but the java jar file does not run. Any
> thoughts?
>
> I am using Http for my commits, i know the http server runs as apache user.
> So i did a su to apache and tried to execute it on the command line that
> worked too. So what am i missing ?

This question is most appropriate for the users mailing list. This
list is about the development of Subversion itself.

Does the user your httpd is running as have access to the
/home/x/triggerContBuild/target/triggerContBuild/trigger/ directory?
Does he have JAVA_HOME set?

Try redirecting the stdout and stderr output from the 'java' command
into a file if you're still having problems, to see why it's not
running.

  • application/pgp-signature attachment: stored
Received on Tue Dec 5 21:17:43 2006

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

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