I've added normalize_groups as part of
https://github.com/ansible/ansible/pull/7867

On Thu, Jun 19, 2014 at 5:35 PM, Michael DeHaan <mich...@ansible.com> wrote:
> That seems reasonable to me.
>
>
>
>
> On Thu, Jun 19, 2014 at 4:33 PM, Michael Peters <michael00pet...@gmail.com>
> wrote:
>>
>> I thought about tackling this along with the proposed "downcase_facts"
>> option for ec2.ini. Something like "normalize_facts" or some such so
>> that anything that's not a letter or number gets converted to an
>> underscore. Would default to false just like downcase_facts.
>>
>> On Thu, Jun 19, 2014 at 5:30 PM, Michael DeHaan <mich...@ansible.com>
>> wrote:
>> > Really we should probably replace all "-" with "_" in tag names so they
>> > can
>> > be cleanly used as variables.
>> >
>> > But then again, the tag had a "-" in it, so I'm not sure that's the
>> > right
>> > thing to do.
>> >
>> > Anyway, variables can't have "-" in them, which is why that happens, so
>> > it's
>> > easy to fix with a convention.
>> >
>> >
>> >
>> >
>> > On Thu, Jun 19, 2014 at 12:28 PM, Michael Peters
>> > <michael00pet...@gmail.com>
>> > wrote:
>> >>
>> >> You can pull it from the hostvars dictionary with something like
>> >>
>> >>
>> >>
>> >> hostvars[inventory_hostname]['ec2_tag_elasticbeanstalk_environment-name']
>> >>
>> >>
>> >>
>> >> On Thu, Jun 19, 2014 at 12:06 PM, Roger Hunwicks
>> >> <roger.hunwi...@gmail.com> wrote:
>> >> > After further investigation...
>> >> >
>> >> > When the playbook runs, on that task I get:
>> >> >
>> >> > fatal: [ec2-54-196-159-144.compute-1.amazonaws.com] => {'msg':
>> >> > "unsupported
>> >> > operand type(s) for -: 'StrictUndefined' and 'StrictUndefined'",
>> >> > 'failed':
>> >> > True}
>> >> >
>> >> > If I define the variable in the group_vars file I get the same error.
>> >> >
>> >> > However, if I change the variable in both the group_vars file and the
>> >> > template to ec2_tag_elasticbeanstalk_environment_name - i.e. with an
>> >> > underscore instead of a minus as the last separator then it works.
>> >> >
>> >> > That implies that the - in the variable name is the issue, but I
>> >> > still
>> >> > don't
>> >> > know the best way to solve it.
>> >> >
>> >> > --
>> >> > 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/14d59022-6c26-4966-bbb7-c10f519231c6%40googlegroups.com.
>> >> >
>> >> > 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 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/CAJQqANdSQNDCfrMuTe9b7em154K3Zp%2BzjCUD1jRV3TAgjCXxCg%40mail.gmail.com.
>> >> 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 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/CA%2BnsWgziWPZiETc%3D8%2BZBsv9By-1X9SZc-w-kLM0EiB5vyLRxvA%40mail.gmail.com.
>> > 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 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/CAJQqANfoNAZrwgMyOX6yORqD0Dkon44ZxM5%2BpYeYVS8L%2B3L7nw%40mail.gmail.com.
>>
>> 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 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/CA%2BnsWgwuMcvhPPX_e2bBGb%2B51u_b%2BKMFbavYL8XPCn3r6ub6xg%40mail.gmail.com.
>
> 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 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/CAJQqANfX_CrzLnQh3nLLVBD%3DyOd5Cw%2BDbhi%3DtuAgbded7ByGcQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to