# # $Id$ # %global with_python3 1 Name: python-redfish Version: 0.4.1 Release: 1%{dist} Summary: Redfish python library License: ASL 2.0 Group: Applications/System Url: https://review.openstack.org/#/q/project:openstack/python-redfish Source: ftp://ftp.mondorescue.org//src/%{name}-%{version}.tar.gz Requires: python-docopt >= 0.6.2,python-tortilla >= 0.4.1,python-jinja2 >= 2.7.3,python-simplejson >= 3.8.1,python-requests >= 2.9.1,python-configparser >= 3.3.0,python-future >= 0.15.2,python-redfish-data BuildArch: noarch BuildRequires: make,python-devel,python-setuptools >= 18,python-future >= 0.15.2,python-docopt >= 0.6.2,python-requests >= 2.9.1,python-simplejson >= 3.8.1,python-configparser >= 3.3.0,python-sphinx_rtd_theme,python-pbr >= 0.8,python-tortilla >= 0.4.1, python-sphinx >= 1.2.3 %description The Redfish API supports dialoging with a Redfish compliant system such as defined by http://www.redfishcertification.org Python2 version. %if %{?with_python3} %package -n python3-redfish Summary: %{summary} / Python 3 library BuildRequires: python3-devel,python3-setuptools >= 18,python3-future >= 0.15.2,python3-docopt >= 0.6.2,python3-requests >= 2.9.1,python3-simplejson >= 3.8.1,python3-sphinx_rtd_theme,python3-pbr >= 0.8,python3-tortilla >= 0.4.1,python3-sphinx >= 1.2.3 Requires: python3-docopt >= 0.6.2,python3-tortilla >= 0.4.1,python3-jinja2 >= 2.7.3,python3-simplejson >= 3.8.1,python3-requests >= 2.9.1,python-redfish-data %description -n python3-redfish The Redfish API supports dialoging with a Redfish compliant system such as defined by http://www.redfishcertification.org Python3 version. %endif # if with_python3 %package -n python-redfish-doc Summary: %{summary} / Documentation BuildRequires: texlive-multirow,texlive-upquote,texlive-wrapfig,texlive-threeparttable,texlive-titlesec,texlive-framed,texlive-capt-of,texlive-latex-bin,texlive-hyphen-base,texlive-cm,texlive-cmap,texlive-ec,texlive-langcode,texlive-babel-english,texlive-fancyhdr,texlive-fancybox,texlive-mdwtools,texlive-parskip,texlive-eqparbox,texlive-times,texlive-helvetic,texlive-courier,texlive-gsftopk-bin,texlive-dvips,texlive-mfware-bin %description -n python-redfish-doc The Redfish API supports dialoging with a Redfish compliant system such as defined by http://www.redfishcertification.org Documentation %package -n python-redfish-data Summary: %{summary} / Data %description -n python-redfish-data The Redfish API supports dialoging with a Redfish compliant system such as defined by http://www.redfishcertification.org Data %prep %setup -q -n %{name}-%{version} # Fix for now as long as setuptools isn't more recent in distributions %if %{?with_python3} perl -pi -e "s|configparser>=3.3.0; python_version < '3'|configparser>=3.3.0|" requirements.txt cp -a . %{py3dir} # python3 doesn't provide configparser at all (cd %{py3dir} ; perl -pi -e "s|configparser>=3.3.0||" requirements.txt) %endif # if with_python3 %build %if %{?with_python3} pushd %{py3dir} %{__python3} setup.py build # Build minimal documentation cd doc make man popd %endif # if with_python3 %{__python} setup.py build # Build minimal documentation cd doc make man make singlehtml make latexpdf %install %if %{?with_python3} pushd %{py3dir} ./install.sh %{__python3} %{buildroot} %{python3_sitelib} %{_prefix} python3-redfish mv %{buildroot}%{_bindir}/redfish-client %{buildroot}%{_bindir}/redfish-client-%{python3_version} mv %{buildroot}%{_bindir}/redfish-check-cartridge %{buildroot}%{_bindir}/redfish-check-cartridge-%{python3_version} popd %endif # if with_python3 ./install.sh %{__python} %{buildroot} %{python_sitelib} %{_prefix} python-redfish ./install.sh %{_docdir} %{buildroot} %{python_sitelib} %{_prefix} python-redfish for i in `ls %{buildroot}/%{_mandir}/man1/*-py2.1*`; do j=`echo $i | perl -p -e 's|-py2||'` cp -a $i $j done %files %doc README.rst examples/[a-z]*.py LICENSE AUTHORS ChangeLog %exclude %{_docdir}/python-redfish/manual/html %exclude %{_docdir}/python-redfish/manual/*.pdf %{_bindir}/redfish-client %{_bindir}/redfish-check-cartridge %dir %{python_sitelib}/redfish %{python_sitelib}/redfish/*.py* %{python_sitelib}/redfish/oem/*.py* %{python_sitelib}/redfish/tests/*.py* %{python_sitelib}/python_redfish* # Needs improvement to host all .1 man pages but not the py3 ones %{_mandir}/man1/python-redfish.1* %{_mandir}/man1/*-py2.1* %if %{?with_python3} %files -n python3-redfish %doc README.rst examples/[a-z]*.py LICENSE AUTHORS ChangeLog %exclude %{_docdir}/python-redfish/manual/html %exclude %{_docdir}/python-redfish/manual/*.pdf %{_bindir}/redfish-client-%{python3_version} %{_bindir}/redfish-check-cartridge-%{python3_version} %dir %{python3_sitelib}/redfish %{python3_sitelib}/redfish/*.py* %{python3_sitelib}/redfish/oem/*.py* %{python3_sitelib}/redfish/oem/__pycache__/*.py* %{python3_sitelib}/redfish/__pycache__/*.py* %{python3_sitelib}/redfish/tests/*.py* %{python3_sitelib}/redfish/tests/__pycache__/*.py* %{python3_sitelib}/python_redfish* %{_mandir}/man1/*-py3.1* %endif # if with_python3 %files -n python-redfish-data %config(noreplace) %{_sysconfdir}/redfish-client.conf %dir %{_datadir}/redfish-client %{_datadir}/redfish-client/templates/* %{_datadir}/redfish-client/*.txt %files -n python-redfish-doc %{_docdir}/python-redfish/manual/html/_static/* %{_docdir}/python-redfish/manual/html/index.html %{_docdir}/python-redfish/manual/*.pdf %changelog * Sat Jan 01 2050 Bruno Cornec 0.5-1 - Updated to 0.5 - TBD () * Wed Mar 08 2017 Bruno Cornec 0.4.1-1 - Updated to 0.4.1 - Fix delivery to Pypi (Bruno Cornec/René Ribaud) - Fix #1670722 to filter all scripts delivered (Bruno Cornec/René Ribaud) - Recover a missing fix from (Zhang Yufei) * Wed Mar 01 2017 Bruno Cornec 0.4-1 - Updated to 0.4 - Adds redfish-client tests with Docker (not activated on gerrit) with multiple distributions (René Ribaud) - Fix #1662225 Remove future module dependencies and Do not use pip in setup.py (René Ribaud) - Update documentation to the fact python-redfish is an OpenStack project (Bruno Cornec) - Adds Moonshot support (fixes for m510 and redfish-check-cartridge script) (René Ribaud) - Adds support for Oem data structure (mandatiry ti get MAC address with some implementation as of now) (René Ribaud) - Update DMTF docs (Bruno Cornec) - Avoid TypeError after _replace when user post a str url and Fix wrong payload in set boot source (Zhang Yufei) - This version provides packaging support for Mageia 5, Fedora 25, CentOS 7 and OpenSUSE 42.2 using project-builder.org 0.14.2+ with a new python-redfish-data package in order to share common content between python2 and python3 packages (Bruno Cornec) * Sat Apr 30 2016 Bruno Cornec 0.3-1 - Updated to 0.3 - First version usable for PoC (Team) - Support for lots of Redfish configuration items added (René Ribaud) - Support for OEM subtrees (René Ribaud) - Use the correct headers for requests (René Ribaud) - Examples reviewed to take advantage of these extensions (René Ribaud) - Usage of jinja2 templates for redfish-client (René Ribaud) - Updated client (René Ribaud) - Usage of a $HOME/.redfish directory for storing configuration and logs (Bruno Cornec) - Adds test with multiple docker containers (René Ribaud) - Documentation review and extension (René Ribaud/Bruno Cornec) - Update DMTF documentation to 1.0.1 (Bruno Cornec) - First packages for Mageia 5 and Fedora 23 using project-builder.org py2 and py3 (Bruno Cornec) * Tue Dec 08 2015 Bruno Cornec 0.2-1 - Updated to 0.2 - first rpm made using project-builder.org (Bruno Cornec) - Update the simple-simulator example (René Ribaud) - Update redfish-client (René Ribaud) - Add both UEFI parameters "Continuous" and "Once" as an example (Vincent Misson) - New function set_parameter and set_parameter_json on Systems Class (Vincent Misson) - New classes in types.py: Bios & Boot (Vincent Misson) - New function get_power() and generic function get_parameter(parameter_name) for class Systems (Vincent Misson) - Create new function: get_serialnumber. Tested with Simulator (v1) + Redfish Proliant 0.9.5 and 1.0 (Vincent Misson) - Various doc updates (Bruno Cornec/René Ribaud) * Wed Sep 09 2015 Bruno Cornec 0.1-1 - Updated to 0.1 - Uses tortilla lib to wrap the REST API (René Ribaud) - Uses python requests to manage login/logout (René Ribaud) - Provides 2 functional working examples with Redfish simulator and ProLiant server or Moonshot Server (René Ribaud) - Remove OpenStack deps as this code has to be usable outside of OpenStack (Bruno Cornec) - Provides a configuration file to handle credentials and connection URL (René Ribaud) - Provides a mapping class to handle multiple versions of Redfish (in this version, 0.95.0 for ProLiant and 1.0.0 for mockup) (René Ribaud) - Provides a first action reset_server to ... reset system The action is commented into simple-proliant.py to not do unexpected reset. (René Ribaud) - Provides a first retrieving function get_bios_version to get the BIOS version of a system. (René Ribaud) - Add basic logging capability (René Ribaud) - Change the documentation to reference Redfish specification. Remove HP and iLO specific references (Samer El-Haj-Mahmoud) - Initial content and Clean up to meet pep8 and doc strings (Devenanda van der Veen)