diff --git a/docs/source/index.rst b/docs/source/index.rst index 083432de4..515643f2d 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -93,7 +93,9 @@ The ``master`` branch should be considered experimental and used with caution. - ``stable-6.0`` Supports Ceph version ``pacific``. This branch requires Ansible version ``2.9``. -- ``master`` Supports the master branch of Ceph. This branch requires Ansible version ``2.10``. +- ``stable-7.0`` Supports Ceph version ``quincy``. This branch requires Ansible version ``2.12``. + +- ``main`` Supports the main (devel) branch of Ceph. This branch requires Ansible version ``2.12``. .. NOTE:: ``stable-3.0`` and ``stable-3.1`` branches of ceph-ansible are deprecated and no longer maintained. diff --git a/infrastructure-playbooks/filestore-to-bluestore.yml b/infrastructure-playbooks/filestore-to-bluestore.yml index 0a8430e53..659d54c8b 100644 --- a/infrastructure-playbooks/filestore-to-bluestore.yml +++ b/infrastructure-playbooks/filestore-to-bluestore.yml @@ -138,7 +138,7 @@ when: item.1.stdout == 'ceph data' - name: umount osd data - mount: + ansible.posix.mount: path: "/var/lib/ceph/osd/{{ cluster }}-{{ (item.0.stdout | from_json).whoami }}" state: unmounted with_together: @@ -147,7 +147,7 @@ when: item.1.stdout == 'ceph data' - name: umount osd lockbox - mount: + ansible.posix.mount: path: "/var/lib/ceph/osd-lockbox/{{ (item.0.stdout | from_json).data.uuid }}" state: unmounted with_together: @@ -441,4 +441,4 @@ "This node has been skipped because OSDs are either" "all bluestore or there's a mix of filestore and bluestore OSDs" when: - - skip_this_node | bool \ No newline at end of file + - skip_this_node | bool diff --git a/infrastructure-playbooks/lv-teardown.yml b/infrastructure-playbooks/lv-teardown.yml index b9ea569cb..4d0654c38 100644 --- a/infrastructure-playbooks/lv-teardown.yml +++ b/infrastructure-playbooks/lv-teardown.yml @@ -40,7 +40,7 @@ changed_when: false - name: tear down any existing osd filesystem - mount: + ansible.posix.mount: path: "{{ item }}" state: unmounted with_items: "{{ old_osd_filesystems.stdout_lines }}" diff --git a/infrastructure-playbooks/purge-cluster.yml b/infrastructure-playbooks/purge-cluster.yml index 50282935b..d3a7abdde 100644 --- a/infrastructure-playbooks/purge-cluster.yml +++ b/infrastructure-playbooks/purge-cluster.yml @@ -75,7 +75,7 @@ with_items: "{{ groups[nfs_group_name] }}" - name: ensure nfs-ganesha mountpoint(s) are unmounted - mount: + ansible.posix.mount: path: "{{ item.split(' ')[1] }}" state: unmounted with_items: @@ -434,7 +434,7 @@ - (containerized_deployment | bool or ceph_volume_present.rc == 0) - name: umount osd data partition - mount: + ansible.posix.mount: path: "{{ item }}" state: unmounted with_items: "{{ mounted_osd.stdout_lines }}" @@ -802,7 +802,7 @@ listen: "remove data" - name: umount osd data partition - mount: + ansible.posix.mount: path: "{{ item }}" state: unmounted with_items: "{{ mounted_osd.stdout_lines }}" diff --git a/infrastructure-playbooks/shrink-osd.yml b/infrastructure-playbooks/shrink-osd.yml index 42d96dddd..b4255f47c 100644 --- a/infrastructure-playbooks/shrink-osd.yml +++ b/infrastructure-playbooks/shrink-osd.yml @@ -161,7 +161,7 @@ delegate_to: "{{ item.0 }}" - name: umount osd lockbox - mount: + ansible.posix.mount: path: "/var/lib/ceph/osd-lockbox/{{ ceph_osd_data_json[item.2]['data']['uuid'] }}" state: absent loop: "{{ _osd_hosts }}" @@ -173,7 +173,7 @@ - ceph_osd_data_json[item.2]['data']['uuid'] is defined - name: umount osd data - mount: + ansible.posix.mount: path: "/var/lib/ceph/osd/{{ cluster }}-{{ item.2 }}" state: absent loop: "{{ _osd_hosts }}" diff --git a/requirements.txt b/requirements.txt index b8b6274aa..4ed60d62d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,4 @@ -# These are Python requirements needed to run ceph-ansible master -ansible>=2.10,<2.11,!=2.9.10 +# These are Python requirements needed to run ceph-ansible main +ansible-core>=2.12,<2.13 netaddr six diff --git a/requirements.yml b/requirements.yml index 9ac7ecfcb..67a675216 100644 --- a/requirements.yml +++ b/requirements.yml @@ -4,3 +4,7 @@ collections: - name: https://opendev.org/openstack/ansible-config_template version: 1.2.1 type: git + - name: ansible.utils + version: '>=2.5.0' + - name: community.general + - name: ansible.posix diff --git a/roles/ceph-validate/tasks/check_system.yml b/roles/ceph-validate/tasks/check_system.yml index dc8cdd6fd..d40453024 100644 --- a/roles/ceph-validate/tasks/check_system.yml +++ b/roles/ceph-validate/tasks/check_system.yml @@ -6,8 +6,8 @@ - name: fail on unsupported ansible version fail: - msg: "Ansible version must be 2.10!" - when: ansible_version.minor|int != 10 + msg: "Ansible version must be 2.12!" + when: ansible_version.minor|int != 12 - name: fail on unsupported system fail: diff --git a/tests/functional/setup.yml b/tests/functional/setup.yml index c72db297c..d06a6e90a 100644 --- a/tests/functional/setup.yml +++ b/tests/functional/setup.yml @@ -69,7 +69,7 @@ # mount -o remount doesn't work on RHEL 8 for now - name: add mount options to / - mount: + ansible.posix.mount: path: '{{ rootmount.mount }}' src: '{{ rootmount.device }}' opts: "noatime,nodiratime{% if ansible_facts['os_family'] == 'RedHat' and ansible_facts['distribution_major_version'] | int < 8 %},nobarrier{% endif %}" diff --git a/tests/requirements.txt b/tests/requirements.txt index 474fa6047..bb6740a46 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,8 +1,8 @@ # These are Python requirements needed to run the functional tests -testinfra>=3,<4 -pytest-xdist==1.28.0 -pytest>=4.6,<5.0 -ansible>=2.10,<2.11,!=2.9.10 +testinfra +pytest-xdist +pytest +ansible-core>=2.12,<2.13 Jinja2>=2.10 netaddr mock diff --git a/tox-update.ini b/tox-update.ini index a578e3e38..94ca977fd 100644 --- a/tox-update.ini +++ b/tox-update.ini @@ -43,6 +43,13 @@ commands= bash -c 'ANSIBLE_CONFIG={envdir}/tmp/ceph-ansible/ansible.cfg ansible-playbook -vv -i {envdir}/tmp/ceph-ansible/tests/functional/all_daemons{env:CONTAINER_DIR:}/hosts {envdir}/tmp/ceph-ansible/tests/functional/setup.yml' +# # use the stable-7.0 branch to deploy an octopus cluster +# git clone -b stable-7.0 --single-branch https://github.com/ceph/ceph-ansible.git {envdir}/tmp/ceph-ansible +# pip install -r {envdir}/tmp/ceph-ansible/tests/requirements.txt +# bash -c 'ANSIBLE_CONFIG={envdir}/tmp/ceph-ansible/ansible.cfg ansible-playbook -vv -i {envdir}/tmp/ceph-ansible/tests/functional/all_daemons{env:CONTAINER_DIR:}/hosts {envdir}/tmp/ceph-ansible/tests/functional/setup.yml' +# # configure lvm, we exclude osd2 given this node uses lvm batch scenario (see corresponding inventory host file) +# bash -c 'ANSIBLE_CONFIG={envdir}/tmp/ceph-ansible/ansible.cfg ansible-playbook -vv -i {envdir}/tmp/ceph-ansible/tests/functional/all_daemons{env:CONTAINER_DIR:}/hosts {envdir}/tmp/ceph-ansible/tests/functional/lvm_setup.yml --extra-vars "osd_scenario=lvm"' + # configure lvm, we exclude osd2 given this node uses lvm batch scenario (see corresponding inventory host file) bash -c 'ANSIBLE_CONFIG={envdir}/tmp/ceph-ansible/ansible.cfg ansible-playbook -vv -i {envdir}/tmp/ceph-ansible/tests/functional/all_daemons{env:CONTAINER_DIR:}/hosts {envdir}/tmp/ceph-ansible/tests/functional/lvm_setup.yml --extra-vars "osd_scenario=lvm" --limit "osds:!osd2"'