I don't understand this. group_vars/ and host_vars/ files are in fact loaded if the host comes from inventory.
Consider just using ansible <hostname> -m ... or ansible-playbook site.yml --limit hostname On Tue, May 27, 2014 at 12:52 AM, Jonathan Ellithorpe < [email protected]> wrote: > Another use case for setting host-specific variables on the command line > is when you use ansible to launch a cluster job with specific parameters > for each host, and you want to do a parameter sweep by wrapping ansible in > a bash script that calculates and sets the host-specific parameter values > for each loop. > > Currently it looks like the only way to do this is to have the bash script > indirectly set host-specific parameter settings by writing a > group_vars/<hostname> file for each <hostname> with the correct parameter > settings before using ansible to launch the job on the cluster. > > On Thursday, January 31, 2013 6:41:07 AM UTC-8, Ernest0x wrote: >> >> Hello, >> >> Is it possible to set a variable from the command line (using the -e >> parameter of ansible-playbook) only for a *specific* host? >> > -- > 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/5776471c-2a89-4c78-979f-c51575a7300a%40googlegroups.com<https://groups.google.com/d/msgid/ansible-project/5776471c-2a89-4c78-979f-c51575a7300a%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%2BnsWgwkLdfDpQZdY-ygH9CKr%3D5AKZJQZx-FgnM-x%3Dxqt_MTFQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
