One solution it to write a proper initscript/upstart/systemd
configuration. Another is to use something like
supervisor/daemontools/runit/monit.

But if you want to continue as is with the least change try adding
nohup infront of the listner line, ansible is probably getting stuck
because the listener is not properly detaching.

On Fri, Dec 12, 2014 at 8:33 AM, Torsten Reinhard
<[email protected]> wrote:
> Hi,
>
> our development team delivers a start script for a "Listener process".
> It looks like:
>
> #!/bin/sh
> BASEDIR=$(dirname $0)
> echo "============================================> Starting Global
> Listener."
> ${BASEDIR}/cm listener &
>
> I can start this script manually and everything is fine.
>
> If I start it using the Ansible shell module, the playbook "hangs" and will
> not return. I tried to use the "command" Module instead, but it is still the
> same.
>
> I than read about the "async" and "poll" options - but I cannot use async
> [time] - because the process started will live as long as it is stopped
> manually.
>
> What is recommended here? Is there a way to use the existing shell script -
> or do we need to modify that script ?
>
> Any help appreciated,
>
> Torsten
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/fb5e147b-0543-482a-8901-f1b331934c85%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
Brian Coca

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAJ5XC8mY%2BPi6-kU9FoQhthYx8i8ckG%2BsQS%3D%2Bor1%2Beum6%3DpMeEA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to