From: Mike Christie Date: Fri, 28 Sep 2018 21:23:10 +0000 (-0500) Subject: igw: valid client CHAP settings. X-Git-Tag: v3.2.0beta3~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=eddb95941b7c57cde28be4d99751f80d30ce6fc4;p=ceph-ansible.git igw: valid client CHAP settings. The linux kernel target layer, LIO, does not support the iscsi target to mix ACLs that have chap enabled and disabled under the same tpg. This patch adds a check and fails if this type of setup is detected. This fixes Red Hat BZ: https://bugzilla.redhat.com/show_bug.cgi?id=1615088 Signed-off-by: Mike Christie --- diff --git a/roles/ceph-validate/tasks/check_iscsi.yml b/roles/ceph-validate/tasks/check_iscsi.yml new file mode 100644 index 000000000..6c6a7670c --- /dev/null +++ b/roles/ceph-validate/tasks/check_iscsi.yml @@ -0,0 +1,10 @@ +--- +- name: fail if unsupported chap configuration + fail: + msg: "Mixing clients with CHAP enabled and disabled is not supported." + with_items: "{{ client_connections | default({}) }}" + when: + - item.status is defined + - item.status == "present" + - item.chap != '' + - " '' in client_connections | selectattr('status', 'match', 'present') | map(attribute='chap') | list" diff --git a/roles/ceph-validate/tasks/main.yml b/roles/ceph-validate/tasks/main.yml index 71b490431..5458a0567 100644 --- a/roles/ceph-validate/tasks/main.yml +++ b/roles/ceph-validate/tasks/main.yml @@ -82,3 +82,8 @@ - radosgw_interface != "dummy" - radosgw_address == "0.0.0.0" - radosgw_address_block == "subnet" + +- name: include check_iscsi.yml + include: check_iscsi.yml + when: + - iscsi_gw_group_name in group_names