On 15/11/2021 10:32, dulhaver via Ansible Project wrote:

I guess the error message you got would be helpful in order to troubleshoot 
your problem

At any rate, nohup is IMHO not the correct way to start an application as a 
server / daemon. Even if some tutorials on the web say so. There is no control 
of the running application, so please use some kind of supervisor (e.g.systemd).

On top of that using the shell module is fragile and not recommended unless the 
command module really doesn't to the trick for you.

Regards

             Racke



On 11/15/2021 9:34 AM Dip Giri <dipakgiri.serv...@gmail.com> wrote:


---

- name: Application setup
  hosts: aws
  gather_facts: no
  tasks:

    - name: Start application
      shell: nohup mvn spring-boot:run -Drun.jvmArguments="-Xmx1024m" &
      args:
        chdir: /home/dipak

*I want to execute nohup command on remote host using ansible but it didn't 
work *


--
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 
ansible-project+unsubscr...@googlegroups.com 
<mailto:ansible-project+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/77f328ac-d41b-44b5-a7ff-3f85f89fbe54n%40googlegroups.com
 
<https://groups.google.com/d/msgid/ansible-project/77f328ac-d41b-44b5-a7ff-3f85f89fbe54n%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
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 
ansible-project+unsubscr...@googlegroups.com 
<mailto:ansible-project+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/2021256539.3416.1636968749678%40office.mailbox.org
 
<https://groups.google.com/d/msgid/ansible-project/2021256539.3416.1636968749678%40office.mailbox.org?utm_medium=email&utm_source=footer>.


--
Ecommerce and Linux consulting + Perl and web application programming.
Debian and Sympa administration.


--
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 ansible-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/cd6fbdfc-18b4-94fd-3f53-471f8714589b%40linuxia.de.

Attachment: OpenPGP_signature
Description: OpenPGP digital signature

Reply via email to