From 6cfc035196fc6a4c73a3c9f70d515f8f1273a4f6 Mon Sep 17 00:00:00 2001 From: Gris Ge Date: Sun, 18 Dec 2022 19:15:56 +0800 Subject: [PATCH] Fix regression of VRF support Signed-off-by: Gris Ge --- 0001-iface-Include-VRF-as-support-type.patch | 38 ++++++++++++++++++++ nmstate.spec | 3 +- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 0001-iface-Include-VRF-as-support-type.patch diff --git a/0001-iface-Include-VRF-as-support-type.patch b/0001-iface-Include-VRF-as-support-type.patch new file mode 100644 index 0000000..2f6c83e --- /dev/null +++ b/0001-iface-Include-VRF-as-support-type.patch @@ -0,0 +1,38 @@ +From b37434e3228b269728e9d7875993417de54d1330 Mon Sep 17 00:00:00 2001 +From: Gris Ge +Date: Thu, 15 Dec 2022 17:11:07 +0800 +Subject: [PATCH] iface: Include VRF as support type + +We accidentally forgot VRF as supported type. +The existing VRF test was skipped by CI hence not been found initially. + +Manually run the test in RHEL host works well. + +Signed-off-by: Gris Ge +--- + rust/src/lib/query_apply/iface.rs | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/rust/src/lib/query_apply/iface.rs b/rust/src/lib/query_apply/iface.rs +index a379960b..888bcbb4 100644 +--- a/rust/src/lib/query_apply/iface.rs ++++ b/rust/src/lib/query_apply/iface.rs +@@ -259,7 +259,7 @@ impl Interface { + } + + impl InterfaceType { +- pub(crate) const SUPPORTED_LIST: [InterfaceType; 13] = [ ++ pub(crate) const SUPPORTED_LIST: [InterfaceType; 14] = [ + InterfaceType::Bond, + InterfaceType::LinuxBridge, + InterfaceType::Dummy, +@@ -273,5 +273,6 @@ impl InterfaceType { + InterfaceType::Vxlan, + InterfaceType::InfiniBand, + InterfaceType::Loopback, ++ InterfaceType::Vrf, + ]; + } +-- +2.39.0 + diff --git a/nmstate.spec b/nmstate.spec index 5ceb3ae..5838dc5 100644 --- a/nmstate.spec +++ b/nmstate.spec @@ -3,13 +3,14 @@ Name: nmstate Version: 2.2.2 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Declarative network manager API License: LGPLv2+ URL: https://github.com/%{srcname}/%{srcname} Source0: %{url}/releases/download/v%{version}/%{srcname}-%{version}.tar.gz Source1: %{url}/releases/download/v%{version}/%{srcname}-%{version}.tar.gz.asc Source2: https://nmstate.io/nmstate.gpg +Patch1: 0001-iface-Include-VRF-as-support-type.patch BuildRequires: patchelf BuildRequires: python3-devel BuildRequires: python3-setuptools