I'm using Ansible to deploy and maintain Hadoop clusters.

I used to define variables in group_vars/all as shown below:

hadoop:
>
> # Variables for core-site.xml
>   nameservice: hadoop-namenode
>
> # Variables for hdfs-site.xml
>   dfs_blocksize: 256m
>
> # Variables for mapred-site.xml
>   mapred_job_tracker: hadoop-jobtracker:8021



However, I have different inventory files, which makes it prone to mistakes.

I can define variables using [all:vars] in inventory files:

[all:vars]
> hadoop_nameservice=hadoop-namenode
>
 

How can I define inventory-specific variables, while still preserving the 
structured definition as in group_vars/all?

Thanks a lot!

-- 
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/a62a724b-d9db-4bb0-980d-91efff5c869b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to