From 52e52d8937e8e57b2bc16f67c3651a358fa6fb77 Mon Sep 17 00:00:00 2001 From: Luigi Toscano Date: Thu, 13 Aug 2020 09:55:08 +0200 Subject: [PATCH] Add a dependency file for os-brick (and add lsscsi) There are a few dependencies which are really os-brick-specific. They are listed in its bindep.txt file, but os-brick is usually installed from pip, so its bindep.txt file is not available. As those dependencies are needed by the various services which use os-brick, move them to their own dependency file (with the addition of the new lsscsi, required by the next os-brick stable release) and make sure that file is parsed when installing the services which require os-brick. Side note: there should be a way to avoid this duplication also for pip-installed libraries (normal services can use files/ or even bindep, but in this case the source is not always available), (temporarily?) duplicate them, as it has been the case for the other os-brick dependencies already listed here. Change-Id: I9ab6e215dbef9ebdb1946da2f9a40ce020ecc95b --- files/debs/cinder | 2 -- files/debs/os-brick | 3 +++ files/rpms-suse/cinder | 1 - files/rpms-suse/os-brick | 2 ++ files/rpms/cinder | 1 - files/rpms/os-brick | 2 ++ functions-common | 9 +++++++++ 7 files changed, 16 insertions(+), 4 deletions(-) create mode 100644 files/debs/os-brick create mode 100644 files/rpms-suse/os-brick create mode 100644 files/rpms/os-brick diff --git a/files/debs/cinder b/files/debs/cinder index c1b79fda47..5d390e24bf 100644 --- a/files/debs/cinder +++ b/files/debs/cinder @@ -1,6 +1,4 @@ lvm2 -open-iscsi -open-iscsi-utils # Deprecated since quantal dist:precise qemu-utils tgt # NOPRIME thin-provisioning-tools diff --git a/files/debs/os-brick b/files/debs/os-brick new file mode 100644 index 0000000000..4148b0c421 --- /dev/null +++ b/files/debs/os-brick @@ -0,0 +1,3 @@ +lsscsi +open-iscsi +open-iscsi-utils # Deprecated since quantal dist:precise diff --git a/files/rpms-suse/cinder b/files/rpms-suse/cinder index 189a232fa7..b39cc79a27 100644 --- a/files/rpms-suse/cinder +++ b/files/rpms-suse/cinder @@ -1,4 +1,3 @@ lvm2 -open-iscsi qemu-tools tgt # NOPRIME diff --git a/files/rpms-suse/os-brick b/files/rpms-suse/os-brick new file mode 100644 index 0000000000..67b33a9861 --- /dev/null +++ b/files/rpms-suse/os-brick @@ -0,0 +1,2 @@ +lsscsi +open-iscsi diff --git a/files/rpms/cinder b/files/rpms/cinder index c21ea08e89..375f93e090 100644 --- a/files/rpms/cinder +++ b/files/rpms/cinder @@ -1,4 +1,3 @@ -iscsi-initiator-utils lvm2 qemu-img targetcli diff --git a/files/rpms/os-brick b/files/rpms/os-brick new file mode 100644 index 0000000000..14ff870557 --- /dev/null +++ b/files/rpms/os-brick @@ -0,0 +1,2 @@ +iscsi-initiator-utils +lsscsi diff --git a/functions-common b/functions-common index d99ad9212f..549f7e8cdc 100644 --- a/functions-common +++ b/functions-common @@ -1219,10 +1219,16 @@ function get_packages { if [[ ! $file_to_parse =~ $package_dir/glance ]]; then file_to_parse="${file_to_parse} ${package_dir}/glance" fi + if [[ ! $file_to_parse =~ $package_dir/os-brick ]]; then + file_to_parse="${file_to_parse} ${package_dir}/os-brick" + fi elif [[ $service == c-* ]]; then if [[ ! $file_to_parse =~ $package_dir/cinder ]]; then file_to_parse="${file_to_parse} ${package_dir}/cinder" fi + if [[ ! $file_to_parse =~ $package_dir/os-brick ]]; then + file_to_parse="${file_to_parse} ${package_dir}/os-brick" + fi elif [[ $service == s-* ]]; then if [[ ! $file_to_parse =~ $package_dir/swift ]]; then file_to_parse="${file_to_parse} ${package_dir}/swift" @@ -1231,6 +1237,9 @@ function get_packages { if [[ ! $file_to_parse =~ $package_dir/nova ]]; then file_to_parse="${file_to_parse} ${package_dir}/nova" fi + if [[ ! $file_to_parse =~ $package_dir/os-brick ]]; then + file_to_parse="${file_to_parse} ${package_dir}/os-brick" + fi elif [[ $service == g-* ]]; then if [[ ! $file_to_parse =~ $package_dir/glance ]]; then file_to_parse="${file_to_parse} ${package_dir}/glance"