buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Boisvert <alex.boisv...@gmail.com>
Subject Re: Running java jar from buildr - not starting
Date Fri, 24 Aug 2012 17:23:06 GMT
Should work... you don't need to escape the ampersand and you shouldn't
need 'nohup'... try:

sh "java -jar  engine_dev.jar  > /var/log/engine/dev/startengine.log &"

On Fri, Aug 24, 2012 at 5:44 AM, Odelya <odelya@alicanto.com> wrote:

> Hi!
>
> In the end of my tasks, I would like to run java's jar.
>
> I wrote the following:
>
> sh "nohup java -jar  engine_dev.jar  \&>
> /var/log/engine/dev/startengine.log
> \&"
>
> And I see in the logs that the command is being executed:
>
> nohup java -jar  engine_dev.jar  &> /var/log/engine/dev/startengine.log &
>
> However, the jar does not start.
>
> If I try "java -jar engine_dev.jar " - than the jar starts but in the same
> terminal. (jenkins output) so I need the nohup so it will run even if
> jenkins logs out of the shell.
>
> If I try the same command with jenkins user (the one that runs buildr) in
> the shell - it works just fine.
>
> What could be the problem?
>
>
>
> --
> View this message in context:
> http://buildr-users.1056619.n5.nabble.com/Running-java-jar-from-buildr-not-starting-tp5706586.html
> Sent from the Buildr Users mailing list archive at Nabble.com.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message