!16 Update to 4.2.0
From: @xiyuanwang Reviewed-by: @han-guangyu Signed-off-by: @han-guangyu
This commit is contained in:
commit
2838b253a5
Binary file not shown.
BIN
netmiko-4.2.0.tar.gz
Normal file
BIN
netmiko-4.2.0.tar.gz
Normal file
Binary file not shown.
@ -1,51 +1,52 @@
|
||||
%global srcname netmiko
|
||||
%global sum Multi-vendor library to simplify Paramiko SSH connections to network devices
|
||||
%global _empty_manifest_terminate_build 0
|
||||
%global common_description \
|
||||
Multi-vendor library to simplify Paramiko SSH connections to network devices
|
||||
|
||||
Name: python-%{srcname}
|
||||
Version: 4.1.2
|
||||
Name: python-netmiko
|
||||
Version: 4.2.0
|
||||
Release: 1
|
||||
Summary: %{sum}
|
||||
License: MIT and ASL 2.0
|
||||
URL: https://pypi.org/project/%{srcname}
|
||||
Source0: https://files.pythonhosted.org/packages/0b/83/030a32a4d728e8cda107243385989af2376e92b6845b4484abf2737ed46c/netmiko-4.1.2.tar.gz
|
||||
|
||||
Summary: Multi-vendor library to simplify legacy CLI connections to network devices
|
||||
License: MIT
|
||||
URL: https://github.com/ktbyers/netmiko
|
||||
Source0: https://files.pythonhosted.org/packages/c9/26/74cb42b86b38069bcc4974fc5fccf670ca9b151cf6cfc5ecd97005cc01ae/netmiko-4.2.0.tar.gz
|
||||
BuildArch: noarch
|
||||
|
||||
%description
|
||||
%{sum}
|
||||
%{common_description}
|
||||
|
||||
%package -n python3-%{srcname}
|
||||
Summary: %{sum}
|
||||
%package -n python3-netmiko
|
||||
Summary: Multi-vendor library to simplify legacy CLI connections to network devices
|
||||
Provides: python-netmiko
|
||||
# Base build requires
|
||||
BuildRequires: python3-devel
|
||||
Requires: python3-paramiko >= 2.6.0
|
||||
Requires: python3-scp >= 0.13.2
|
||||
Requires: python3-pyserial
|
||||
Requires: python3-tenacity
|
||||
Requires: python3-textfsm
|
||||
# For import test, keep the same as requirements
|
||||
BuildRequires: python3-paramiko
|
||||
BuildRequires: python3-scp
|
||||
BuildRequires: python3-pyserial
|
||||
BuildRequires: python3-tenacity
|
||||
BuildRequires: python3-textfsm
|
||||
BuildRequires: python3-setuptools
|
||||
%if 0%{?rhel}
|
||||
BuildRequires: python3-importlib-resources
|
||||
%endif
|
||||
BuildRequires: python3-pbr
|
||||
BuildRequires: python3-pip
|
||||
BuildRequires: python3-wheel
|
||||
# General build requires
|
||||
BuildRequires: python3-ntc-templates
|
||||
BuildRequires: python3-paramiko
|
||||
BuildRequires: python3-pyserial
|
||||
BuildRequires: python3-pyyaml
|
||||
BuildRequires: python3-scp
|
||||
BuildRequires: python3-textfsm
|
||||
# General requires
|
||||
Requires: python3-ntc-templates
|
||||
Requires: python3-paramiko
|
||||
Requires: python3-pyserial
|
||||
Requires: python3-pyyaml
|
||||
Requires: python3-scp
|
||||
Requires: python3-textfsm
|
||||
%description -n python3-netmiko
|
||||
%{common_description}
|
||||
|
||||
%{?python_provide:%python_provide python3-%{srcname}}
|
||||
|
||||
%description -n python3-%{srcname}
|
||||
%{sum} - package for Python 3.
|
||||
|
||||
# FIXME: build the documentation, when upstream starts shipping its sources:
|
||||
# https://github.com/ktbyers/netmiko/issues/507
|
||||
%package help
|
||||
Summary: Multi-vendor library to simplify legacy CLI connections to network devices
|
||||
Provides: python3-netmiko-doc
|
||||
%description help
|
||||
%{common_description}
|
||||
|
||||
%prep
|
||||
%autosetup -n %{srcname}-%{version}
|
||||
# NOTE(dtantsur): ntc-templates is not packaged, we're using python3-textfsm
|
||||
# instead. Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1927400.
|
||||
sed -i '/ntc-templates/d' setup.py
|
||||
%autosetup -n netmiko-%{version}
|
||||
|
||||
%build
|
||||
%py3_build
|
||||
@ -53,20 +54,45 @@ sed -i '/ntc-templates/d' setup.py
|
||||
%install
|
||||
%py3_install
|
||||
|
||||
%check
|
||||
# FIXME: run unit tests, when/if upstream creates them:
|
||||
# https://github.com/ktbyers/netmiko/issues/509
|
||||
%{__python3} -c "from netmiko import ConnectHandler"
|
||||
install -d -m755 %{buildroot}/%{_pkgdocdir}
|
||||
if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
|
||||
if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
|
||||
if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
|
||||
if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
|
||||
pushd %{buildroot}
|
||||
if [ -d usr/lib ]; then
|
||||
find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
if [ -d usr/lib64 ]; then
|
||||
find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
if [ -d usr/bin ]; then
|
||||
find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
if [ -d usr/sbin ]; then
|
||||
find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
touch doclist.lst
|
||||
if [ -d usr/share/man ]; then
|
||||
find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
|
||||
fi
|
||||
popd
|
||||
mv %{buildroot}/filelist.lst .
|
||||
mv %{buildroot}/doclist.lst .
|
||||
|
||||
%files -n python3-%{srcname}
|
||||
%{_bindir}/netmiko-cfg
|
||||
%{_bindir}/netmiko-grep
|
||||
%{_bindir}/netmiko-show
|
||||
%license LICENSE
|
||||
%doc README.md
|
||||
%{python3_sitelib}/*
|
||||
#%check
|
||||
#%{__python3} setup.py test
|
||||
|
||||
%files -n python3-netmiko -f filelist.lst
|
||||
%dir %{python3_sitelib}/*
|
||||
|
||||
%files help -f doclist.lst
|
||||
%{_docdir}/*
|
||||
|
||||
%changelog
|
||||
* Fri Jul 14 2023 OpenStack_SIG <openstack@openeuler.org> - 4.2.0-1
|
||||
- Upgrade package python3-netmiko to version 4.2.0
|
||||
|
||||
* Wed Dec 07 2022 jiangxinyu <jiangxinyu@kylinos.cn> - 4.1.2-1
|
||||
- Update package to version 4.1.2
|
||||
|
||||
@ -80,4 +106,5 @@ sed -i '/ntc-templates/d' setup.py
|
||||
- Change url and license
|
||||
|
||||
* Sat Mar 13 2021 zhaorenhai <zhaorenhai@hotmail.com> - 3.3.3-1
|
||||
- Init package and spec, referenced from Fedora.
|
||||
- Init package and spec, referenced from Fedora.
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user