Hi

On Wed, Aug 06, 2014 at 03:00:59AM -0700, Julián Jamardo wrote:
> Hi everybody,
> 
> I'm deploying Adobe CQ projects with Ansible, everything works fine except the
> restart at the end of the deployment.
> 
> The excerpt of the my playbook:
> 
>   - name: Stop of CQ instance
>     command: sudo /etc/init.d/cq stop
> 
>   - name: make sure CQ is stopped
>     service: name=cq state=stopped        (The Stop works fine, it checks the
> state and jumps to the next Task)
> 
> [wNR84w9g]
>    
>   - name: Start of CQ instance 
>     command: sudo /etc/init.d/cq start     ( The instance starts well but the
> playbook stops here and ignores the further tasks )

I have seen that before on badly written init scripts that do not
detach from the TTY properly. (Or fails to become a process group
leader - not sure which).

Try an experiment: Start the CQ service using ansible. And watch
ansible hang. Leave it hanging.  Then (from a different ssh session),
stop the service manually.  Does ansible then continue?

If so, it is likely that the CQ instance has the terminal open that
was used for starting it.

Short of fixing the init script, making ansible run:

   sudo nohup e/tc/init.d/cq start

may work then.

> 
> [AAAAAElFTk]
>  
> I think it is because it doesn't get any Return Code..
> Is there a possibility to jump to the next task without any Return Code /
> Output?
> Afterwards I would check if the port 4503 is available and go on cleaning the
> dispatcher cache and deleting the precompiled jsps as my last tasks.
> 
>   - name: CQ Port Monitoring
>     wait_for: port=4503 delay=300
> 
>   - name: Clean Dispatcher Cache
>     shell: rm -rf /opt/daycq/dispatcher/cache/publish*/*
> 
>   - name: Delete precompiled jsps
>     command: curl -X DELETE http://localhost:4503/var/classes/org/apache/jsp/
> apps/ -u {{username}}:{{password}}
> 
> 
> Thank you in advance
> 
> Best regards,
> Julián Jamardo
> 

-- 
Karl E. Jorgensen

-- 
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 post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/20140806180200.GA31039%40hawking.
For more options, visit https://groups.google.com/d/optout.

Reply via email to