Host Group not being recognised

Hi,

I recently upgraded to 1.9 and I’ve noticed a host group I created is not being recognised. Here is the playbook extract:

tasks:

  • name: Provision test t2 micro instance
    ec2:
    aws_access_key: “{{ ec2_access_key }}”
    aws_secret_key: “{{ ec2_secret_key }}”
    region: “{{ region }}”
    key_name: “{{ key_name }}”
    instance_type: “{{ instance_type }}”
    image: “{{ image }}”
    wait: “{{ wait }}”
    wait_timeout: “{{ wait_timeout }}”
    group: “{{ group }}”
    instance_tags:
    name: “{{ inventory_hostname }}”
    tier: web
    env: prod
    assign_public_ip: yes
    vpc_subnet_id: “{{ vpc_subnet_id }}”
    register: ec2

  • name: Add all instance public IPs to host group
    add_host: hostname={{ item.public_ip }} groups=new_webservers
    with_items: ec2.instances

  • name: Wait for SSH to come up
    wait_for: host={{ item.public_dns_name }} port=22 delay=60 timeout=320 state=started
    with_items: ec2.instances

  • hosts: new_webservers
    tasks:

  • name: configure and deploy the webservers
    yum: name={{ item }} state=present
    with_items:

  • httpd

  • php

  • python

  • service: name=httpd state=started

I get:

PLAY [new_webservers] *********************************************************
skipping: no hosts matched

And therefore the last section is not run. This playbook was working ok under ansible-1.8.4 so I was wondering if it’s a bug?

I am running ansible-1.9.0.1 on Centos 6

Thanks,

Anton

Something is definitely not right here, I end up with the following if I remove the “–limit” clause I was applying:

http://pastebin.com/9YFXGPY6

This is a log entry for the same playbook prior to the upgrade:

http://pastebin.com/ZYLYZtGV

Yum logs show I upgraded 2 days later.

Does anyone think this is a bug and is anyone else seeing this?

Thanks,

Anton

I downgraded to ansible-1.8.4-1.el6.noarch and I see the same issue, so really confused now!