From 5747caf97b606d13f13876a3f45731f9364c76cb Mon Sep 17 00:00:00 2001 From: Tomas Bzatek Date: Thu, 2 May 2024 16:42:23 +0200 Subject: [PATCH] * Thu May 02 2024 Tomas Bzatek - 2.8-2 - Install custom nvmf-connect-nbft.sh NetworkManager hook --- .nvme-cli.metadata | 1 + nvme-cli.spec | 9 ++++++++- nvmf-connect-nbft.sh | 5 +++++ 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 .nvme-cli.metadata create mode 100644 nvmf-connect-nbft.sh diff --git a/.nvme-cli.metadata b/.nvme-cli.metadata new file mode 100644 index 0000000..34c9614 --- /dev/null +++ b/.nvme-cli.metadata @@ -0,0 +1 @@ +33eaae0a2334451553952ac701f8568a52fd2a98 nvme-cli-2.9.1.tar.gz diff --git a/nvme-cli.spec b/nvme-cli.spec index 50242c2..8ec4069 100644 --- a/nvme-cli.spec +++ b/nvme-cli.spec @@ -3,12 +3,13 @@ Name: nvme-cli Version: 2.9.1 -Release: 1%{?dist} +Release: 2%{?dist} Summary: NVMe management command line interface License: GPL-2.0-only URL: https://github.com/linux-nvme/nvme-cli Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz +Source1: nvmf-connect-nbft.sh Patch0: 0001-Revert-fabrics-Use-corresponding-hostid-when-hostnqn.patch @@ -40,6 +41,8 @@ nvme-cli provides NVM-Express user space tooling for Linux. %install %meson_install +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/NetworkManager/dispatcher.d +install -p -m 755 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/NetworkManager/dispatcher.d # Do not install the dracut rule yet. See rhbz 1742764 # Do we want to keep this here? Now that we have boot support for nvme/fc + tcp? @@ -70,6 +73,7 @@ rm -rf %{buildroot}%{_pkgdocdir}/nvme # Do not install the dracut rule yet. See rhbz 1742764 # Is this still true? Now that we support nvme-of boot, do we want to install this file? # /usr/lib/dracut/dracut.conf.d/70-nvmf-autoconnect.conf +%{_sysconfdir}/NetworkManager/dispatcher.d/nvmf-connect-nbft.sh %post if [ $1 -eq 1 ] || [ $1 -eq 2 ]; then @@ -90,6 +94,9 @@ if [ $1 -eq 1 ] || [ $1 -eq 2 ]; then fi %changelog +* Tue May 07 2024 Tomas Bzatek - 2.9.1-2 +- Install custom nvmf-connect-nbft.sh NetworkManager hook (RHEL-18912) + * Tue May 07 2024 Maurizio Lombardi - 2.9.1-1 - Update to version 2.9.1 diff --git a/nvmf-connect-nbft.sh b/nvmf-connect-nbft.sh new file mode 100644 index 0000000..1dc0324 --- /dev/null +++ b/nvmf-connect-nbft.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +if [[ "$1" == nbft* ]] && [[ "$2" == "up" ]]; then + systemctl start nvmf-connect-nbft.service +fi