Remove tgtd and scsi-target-utils support in CentOS/RHEL 8

In CentOS/RHEL 8 there is no scsi-target-utils package, nor is it
available in EPEL. In RHEL 7 and beyond the LIO kernel subsystem can be
used instead of the tgtd daemon.

This change removes support for the SCSI target daemon on CentOS/RHEL 8.
The 'tgtd' image is no longer available for CentOS/RHEL 8.

Change-Id: I56f230d66f75dd0546325676278f91579f08c822
Signed-off-by: Maciej Kucia <maciej@kucia.net>
Co-Authored-By: Maciej Kucia <maciej@kucia.net>
Co-Authored-By: Mark Goddard <mark@stackhpc.com>
Related: blueprint centos-rhel-8
Depends-On: https://review.opendev.org/#/c/702417
(cherry picked from commit 946749312f)
This commit is contained in:
Maciej Kucia 2018-10-28 23:14:49 +01:00 committed by Mark Goddard
parent ea8f03da6e
commit 42ffd3b680
4 changed files with 24 additions and 5 deletions

View File

@ -236,7 +236,6 @@ RUN yum-config-manager --enable rhel-7-server-optional-rpms \
'lvm2',
'ncurses',
'procps-ng',
'scsi-target-utils',
'socat',
'sudo',
'which'
@ -250,6 +249,11 @@ RUN yum-config-manager --enable rhel-7-server-optional-rpms \
'python'
] %}
{% endif %}
{% if distro_package_manager == 'yum' %}
{% set base_centos_binary_packages = base_centos_binary_packages + [
'scsi-target-utils',
] %}
{% endif %}
# Install base packages
{{ macros.install_packages( base_centos_binary_packages | customizable("centos_binary_packages")) }}
@ -266,12 +270,16 @@ RUN yum-config-manager --enable rhel-7-server-optional-rpms \
'lvm2',
'ncurses',
'procps-ng',
'scsi-target-utils',
'socat',
'sudo',
'tar',
'which'
] %}
{% if distro_package_manager == 'yum' %}
{% set base_centos_source_packages = base_centos_source_packages + [
'scsi-target-utils',
] %}
{% endif %}
# Update packages
{{ macros.install_packages( base_centos_source_packages | customizable("centos_source_packages")) }}

View File

@ -9,7 +9,6 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
{% set cinder_volume_packages = [
'nfs-utils',
'nvmetcli',
'scsi-target-utils',
'sysfsutils',
'targetcli'
] %}
@ -26,7 +25,9 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
{{ macros.install_packages(cinder_volume_packages | customizable("packages")) }}
{% block cinder_volume_redhat_setup %}
{% if distro_package_manager == 'yum' %}
RUN sed -i '1 i include /var/lib/cinder/volumes/*' /etc/tgt/tgtd.conf
{% endif %}
{% endblock %}
{% elif base_package_type == 'deb' %}

View File

@ -6,10 +6,13 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
{% import "macros.j2" as macros with context %}
{% if base_package_type == 'rpm' %}
{% set tgtd_packages = ['scsi-target-utils'] %}
{{ macros.install_packages(tgtd_packages | customizable("packages")) }}
{% if distro_package_manager == 'dnf' %}
RUN echo 'Not available for {{ base_distro }}' \
&& /bin/false
{% else %}
RUN sed -i '1 i include /var/lib/cinder/volumes/*' /etc/tgt/tgtd.conf
{% endif %}
{% elif base_package_type == 'deb' %}
{% set tgtd_packages = ['tgt'] %}

View File

@ -0,0 +1,7 @@
---
upgrade:
- |
Support for the SCSI target daemon (``tgtd``) has been removed for
CentOS/RHEL 8. In CentOS/RHEL 7 and beyond LIO kernel subsystem can be
used instead of the ``tgtd`` daemon. The ``tgtd`` image is no longer
available for CentOS/RHEL 8.