some v10 Juno playbooks containing a wrong host pattern

Bug #1438118 reported by Serge van Ginderachter
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack-Ansible
Invalid
Undecided
Serge van Ginderachter
Icehouse
Fix Released
Low
Serge van Ginderachter
Juno
Fix Released
Low
Serge van Ginderachter
Trunk
Invalid
Undecided
Serge van Ginderachter

Bug Description

Verision: tag: 10.1.2

Most [patterns where a part of the inventory needs to be excluded, are correct, as here:

~/os-ansible-deployment/rpc_deployment$ grep hosts: playbooks/* -r | grep ':!'
playbooks/infrastructure/galera-add-node.yml:- hosts: galera:!galera[0]
playbooks/infrastructure/rabbit-add-node.yml:- hosts: rabbit:!rabbit[0]
playbooks/openstack/keystone.yml:- hosts: keystone:!keystone[0]
playbooks/openstack/nova-compute-keys.yml:- hosts: nova_compute:!nova_compute[0]
playbooks/openstack/horizon.yml:- hosts: horizon_all:!horizon_all[0]
playbooks/openstack/rpc-support-api.yml:- hosts: utility:neutron_all:!utility[0]
playbooks/openstack/nova-api-ec2.yml:- hosts: nova_api_ec2:!nova_api_ec2[0]
playbooks/openstack/horizon-ssl.yml:- hosts: horizon_all:!horizon_all[0]
playbooks/openstack/keystone-local-keys.yml:- hosts: keystone:!keystone[0]
playbooks/openstack/nova-api-os-compute.yml:- hosts: nova_api_os_compute:!nova_api_os_compute[0]
playbooks/openstack/neutron-server.yml:- hosts: neutron_server:!neutron_server[0]

But three instances have it wronf:

~/os-ansible-deployment/rpc_deployment$ grep hosts: playbooks/* -r | grep '!:'
playbooks/openstack/heat-api.yml:- hosts: heat_api!:heat_api[0]
playbooks/openstack/cinder-api.yml:- hosts: cinder_api!:cinder_api[0]
playbooks/openstack/glance-api.yml:- hosts: glance_api!:glance_api[0]

Which is a fault in the syntax, though ansible does not complain about it. The bang is not followed by any pattern, so no exclude happens here.

In these cases, the playbook also run on the first host, (which is probably fine, as these get a subset of what already ran previously on them specificly.)

Tags: 10.1.2
Revision history for this message
Kevin Carter (kevin-carter) wrote :

This issue also effects icehouse on the following files.

rpc_deployment/playbooks/openstack/cinder-api.yml:54:- hosts: cinder_api!:cinder_api[0]
rpc_deployment/playbooks/openstack/glance-api.yml:49:- hosts: glance_api!:glance_api[0]
rpc_deployment/playbooks/openstack/heat-api.yml:42:- hosts: heat_api!:heat_api[0]

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to os-ansible-deployment (icehouse)

Fix proposed to branch: icehouse
Review: https://review.openstack.org/169506

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to os-ansible-deployment (juno)

Fix proposed to branch: juno
Review: https://review.openstack.org/169507

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to os-ansible-deployment (icehouse)

Fix proposed to branch: icehouse
Review: https://review.openstack.org/169674

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on os-ansible-deployment (icehouse)

Change abandoned by Matt Thompson (<email address hidden>) on branch: icehouse
Review: https://review.openstack.org/169674
Reason: Abandoning as it may be better to cherry pick once juno commit has merged (so that we get the 'cherry-picked from' line added to commit message.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to os-ansible-deployment (juno)

Reviewed: https://review.openstack.org/169507
Committed: https://git.openstack.org/cgit/stackforge/os-ansible-deployment/commit/?id=a50f1917f0085024349f8e514e2f82e2a2016960
Submitter: Jenkins
Branch: juno

commit a50f1917f0085024349f8e514e2f82e2a2016960
Author: Serge van Ginderachter <email address hidden>
Date: Tue Mar 31 22:11:53 2015 +0200

    Correct a syntax error in some hosts: patterns

    Exclusions have a bang preceding it, after the pattern separator.
    Not `pattern1!:pattern2' but `pattern1:!pattern2'

    Change-Id: I594ed52dbef9f6d6ed82ff5a440bc94670979a13
    Partial-Bug: #1438118

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to os-ansible-deployment (icehouse)

Reviewed: https://review.openstack.org/169506
Committed: https://git.openstack.org/cgit/stackforge/os-ansible-deployment/commit/?id=2313fd3e96bd8e058c3e571f0cdb220dc52ec19f
Submitter: Jenkins
Branch: icehouse

commit 2313fd3e96bd8e058c3e571f0cdb220dc52ec19f
Author: Serge van Ginderachter <email address hidden>
Date: Tue Mar 31 22:24:44 2015 +0200

    Correct a syntax error in some hosts: patterns

    Exclusions have a bang preceding it, after the pattern separator.
    Not `pattern1!:pattern2' but `pattern1:!pattern2'

    Change-Id: I594ed52dbef9f6d6ed82ff5a440bc94670979a13
    Partial-Bug: #1438118

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.