Support Ansible 2.5

Raises the maximum Ansible version in requirements.txt to Ansible 2.5.x
for both kayobe and kolla ansible.

Also removes the hack to use a patched parted module for ceph block
device management, as Ansible 2.4 contains the required fix.

Change-Id: I0d2f564eb1ddb63b07829d6f0d918af26887db97
Story: 2001649
Task: 6668
This commit is contained in:
Mark Goddard 2018-04-18 15:56:59 +01:00
parent f034ae4741
commit 07b2f06a82
11 changed files with 24 additions and 38 deletions

View File

@ -1,9 +1,8 @@
---
- name: Ensure Ceph disk are tagged
hosts: overcloud
hosts: overcloud
tags:
- kolla-ceph
roles:
- role: stackhpc.parted-1-1
- role: kolla-ceph
when: kolla_enable_ceph | bool

View File

@ -71,5 +71,6 @@
dest: "{{ kolla_ansible_venv }}/lib/python2.7/site-packages/selinux"
state: link
when:
- ansible_os_family == 'RedHat'
- ansible_selinux != False
- ansible_selinux.status != 'disabled'

View File

@ -7,4 +7,4 @@ kolla-ansible=={{ kolla_openstack_release }}
{% endif %}
# Limit the version of ansible used by kolla-ansible to avoid new releases from
# breaking tested code. Changes to this limit should be tested.
ansible<2.4
ansible<2.6

View File

@ -1,5 +1,4 @@
---
# (ktibi) Need to remove parted_1_1 module when kayobe will support ansible 2.4
- name: Ensure required packages are installed
package:
@ -10,18 +9,18 @@
- name: Check the presence of a partition on the OSD disks
become: True
parted_1_1:
parted:
device: "{{ item.osd }}"
with_items: "{{ ceph_disks }}"
register: "disk_osd_info"
- name: Check the presence of a partition on the journal disks
become: True
parted_1_1:
parted:
device: "{{ item.journal }}"
with_items: "{{ ceph_disks }}"
register: "disk_journal_info"
when:
when:
- item.journal is defined
- name: Fail if the Ceph OSD disks have already a partition
@ -51,7 +50,7 @@
- name: Create tag partition for Ceph OSD
become: True
parted_1_1:
parted:
device: "{{ item.item.osd }}"
number: 1
label: gpt
@ -68,7 +67,7 @@
- name: Create tag partition for Ceph external journal
become: True
parted_1_1:
parted:
device: "{{ item.item.journal }}"
number: 1
label: gpt

View File

@ -22,7 +22,7 @@
- name: Create tag partition for the fake OSD
become: True
parted_1_1:
parted:
device: "{{ osd_tempfile.path }}"
number: 1
label: gpt
@ -34,7 +34,7 @@
- name: Create tag partition for the fake journal
become: True
parted_1_1:
parted:
device: "{{ journal_tempfile.path }}"
number: 1
label: gpt
@ -45,10 +45,6 @@
osd_id: "{{ osd_tempfile.path | basename }}{{ ansible_hostname }}"
- block:
- name: Import parted role
include_role:
name: ../../stackhpc.parted-1-1
- name: Test the kolla-ceph role
include_role:
name: ../../kolla-ceph
@ -58,7 +54,7 @@
journal: "{{ journal_tempfile.path }}"
- name: Get name of fake OSD partition
parted_1_1:
parted:
device: "{{ osd_tempfile.path }}"
register: "disk_osd_info"
become: True
@ -80,7 +76,7 @@
expected: "{{ 'KOLLA_CEPH_OSD_BOOTSTRAP_' ~ ((osd_tempfile.path | basename ~ ansible_hostname) | hash('md5'))[:9] }}"
- name: Get name of fake journal partition
parted_1_1:
parted:
device: "{{ journal_tempfile.path }}"
register: "disk_journal_info"
become: True

View File

@ -21,7 +21,7 @@
- name: Create tag partition for the fake OSD
become: True
parted_1_1:
parted:
device: "{{ osd_tempfile.path }}"
number: 1
label: gpt
@ -33,7 +33,7 @@
- name: Create tag partition for the fake journal
become: True
parted_1_1:
parted:
device: "{{ journal_tempfile.path }}"
number: 1
label: gpt
@ -44,10 +44,6 @@
osd_id: "{{ (osd_tempfile.path | basename ~ ansible_hostname) }}"
- block:
- name: Import parted role
include_role:
name: ../../stackhpc.parted-1-1
- name: Test the kolla-ceph role
include_role:
name: ../../kolla-ceph
@ -57,7 +53,7 @@
journal: "{{ journal_tempfile.path }}"
- name: Get name of fake OSD partition
parted_1_1:
parted:
device: "{{ osd_tempfile.path }}"
register: "disk_osd_info"
become: True
@ -79,7 +75,7 @@
expected: "{{ 'KOLLA_CEPH_DATA_' ~ ((osd_tempfile.path | basename ~ ansible_hostname)| hash('md5'))[:9] }}"
- name: Get name of fake journal partition
parted_1_1:
parted:
device: "{{ journal_tempfile.path }}"
register: "disk_journal_info"
become: True

View File

@ -20,10 +20,6 @@
command: fallocate -l 10M {{ journal_tempfile.path }}
- block:
- name: Import parted role
include_role:
name: ../../stackhpc.parted-1-1
- name: Test the kolla-ceph role
include_role:
name: ../../kolla-ceph
@ -33,7 +29,7 @@
journal: "{{ journal_tempfile.path }}"
- name: Get name of fake OSD partition
parted_1_1:
parted:
device: "{{ osd_tempfile.path }}"
register: "disk_osd_info"
become: True
@ -55,7 +51,7 @@
expected: "{{ 'KOLLA_CEPH_OSD_BOOTSTRAP_' ~ ((osd_tempfile.path | basename ~ ansible_hostname)| hash('md5'))[:9] }}"
- name: Get name of fake journal partition
parted_1_1:
parted:
device: "{{ journal_tempfile.path }}"
register: "disk_journal_info"
become: True

View File

@ -13,10 +13,6 @@
command: fallocate -l 10M {{ tempfile.path }}
- block:
- name: Import parted role
include_role:
name: ../../stackhpc.parted-1-1
- name: Test the kolla-ceph role
include_role:
name: ../../kolla-ceph
@ -25,7 +21,7 @@
- osd: "{{ tempfile.path }}"
- name: Get name of fake partition
parted_1_1:
parted:
device: "{{ tempfile.path }}"
register: "disk_osd_info"
become: True

View File

@ -0,0 +1,4 @@
---
features:
- Adds support for the Ansible 2.5 release. The version requirement has been
increased for both kayobe and kolla ansible.

View File

@ -7,7 +7,7 @@ pbr>=2.0 # Apache-2.0
# with the fix backported. It can be installed by uncommenting the following
# line and commenting the one after.
# -e git+https://github.com/stackhpc/ansible@issue-30350-2.3#egg=ansible-issue-30350-2.3 # GPLv3
ansible<2.4.0 # GPLv3
ansible>=2.4.0,<2.6.0 # GPLv3
cliff>=2.5.0 # Apache
netaddr!=0.7.16,>=0.7.13 # BSD
PyYAML>=3.10.0 # MIT

View File

@ -8,7 +8,6 @@
- src: https://github.com/stackhpc/ansible-users
version: append
name: singleplatform-eng.users
- src: stackhpc.parted-1-1
- src: stackhpc.drac
- src: stackhpc.drac-facts
- src: stackhpc.grafana-conf