Blob Blame Raw
%{!?upstream_version: %global upstream_version %{version}%{?milestone}}

%global sname glanceclient

%global common_desc \
This is a client for the OpenStack Glance API. There's a Python API (the \
glanceclient module), and a command-line script (glance). Each implements \
100% of the OpenStack Glance API.

Name:             python-glanceclient
Epoch:            1
Version:          2.10.0
Release:          2%{?dist}
Summary:          Python API and CLI for OpenStack Glance

License:          ASL 2.0

BuildArch:        noarch

BuildRequires:    git


%package -n python3-%{sname}
Summary:          Python API and CLI for OpenStack Glance
%{?python_provide:%python_provide python3-glanceclient}

BuildRequires:    python3-devel
BuildRequires:    python3-setuptools
BuildRequires:    python3-pbr

Requires:         python3-keystoneauth1 >= 3.3.0
Requires:         python3-oslo-i18n >= 3.15.3
Requires:         python3-oslo-utils >= 3.33.0
Requires:         python3-pbr
Requires:         python3-prettytable
Requires:         python3-pyOpenSSL >= 16.2.0
Requires:         python3-requests
Requires:         python3-six >= 1.10.0
Requires:         python3-warlock
Requires:         python3-wrapt

%description -n python3-%{sname}

%package doc
Summary:          Documentation for OpenStack Glance API Client

BuildRequires:    python3-sphinx
BuildRequires:    python3-openstackdocstheme
BuildRequires:    python3-keystoneauth1
BuildRequires:    python3-oslo-utils
BuildRequires:    python3-prettytable
BuildRequires:    python3-pyOpenSSL >= 16.2.0
BuildRequires:    python3-warlock

%description      doc

This package contains auto-generated documentation.

%autosetup -n %{name}-%{upstream_version} -S git

rm -rf {,test-}requirements.txt


# Delete tests
rm -fr %{buildroot}%{python3_sitelib}/glanceclient/tests

mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d
install -pm 644 tools/glance.bash_completion \

# generate html docs
%{__python3} build_sphinx -b html
# generate man page
%{__python3} build_sphinx -b man
install -p -D -m 644 doc/build/man/glance.1 %{buildroot}%{_mandir}/man1/glance.1

%files -n python3-%{sname}
%license LICENSE
%doc README.rst

%files doc
%doc doc/build/html
%license LICENSE

* Wed Jan 31 2019 Yatin Karel <> 1:2.10.0-2
- Drop python2 sub package

* Wed Apr 18 2018 RDO <> 1:2.10.0-1
- Update to 2.10.0

* Sat Feb 10 2018 RDO <> 1:2.9.1-1
- Update to 2.9.1