What's your question?

Thanks.


On Wed, May 21, 2014 at 7:28 AM, Sacha Vukovic <[email protected]>wrote:

> Hello,
>
> after reading this post :
> https://groups.google.com/forum/#!topic/ansible-project/XbVNoUED2cU
> http://docs.ansible.com/intro_inventory.html
>
> I have a similar question with inventory file,
>
> I want to provisionning on the same host two tomcat using same role, but
> http port, path must be different.
>
> Example:
>
> In my inventory file prod.hosts
> [tomcat1]
> host1
>
> [tomcat2]
> host1
>
> [tomcat1:vars]
> product_dir='/home/produit/tomcat1'
> [tomcat2:vars]
> product_dir='/home/produit/tomcat2'
>
> In site.yml
> - hosts: tomcat1
>   user: root
>   pre_tasks:
>      - debug: msg={{product_dir}}
>
> - hosts: tomcat2
>   user: root
>   pre_tasks:
>      - debug: msg={{product_dir}}
>
> playbook:
>
> PLAY [tomcat1]
> ****************************************************************
>
> GATHERING FACTS
> ***************************************************************
> ok: [host1]
>
> TASK: [debug msg={{product_dir}}]
> *********************************************
> ok: [srv-vid-tux48] => {
>     "msg": "/data/produits/tomcat1"
> }
>
> PLAY [tomcat2]
> ****************************************************************
>
> GATHERING FACTS
> ***************************************************************
> ok: [srv-vid-tux48]
>
> TASK: [debug msg={{product_dir}}]
> *********************************************
> ok: [srv-vid-tux48] => {
>     "msg": "/data/produits/tomcat1"
> }
>
>
> ansible version 1.6.1
>
>  --
> 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/2535ea07-fabd-4c5a-94f2-2c2fbc8cfe23%40googlegroups.com<https://groups.google.com/d/msgid/ansible-project/2535ea07-fabd-4c5a-94f2-2c2fbc8cfe23%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CA%2BnsWgzw%3DgPO7-Lm4_midZuG5VMMOKsaKTFeq0Og%2ByuzTeR7TQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to