python-apache-libcloud/python-apache-libcloud.spec

100 lines
3.4 KiB
RPMSpec
Raw Normal View History

#
# spec file for package python-apache-libcloud
#
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
# No longer build for python2
%define skip_python2 1
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%bcond_without python2
Name: python-apache-libcloud
- Update to 3.2.0: * [OpenStack] Add ex_get_network() to the OpenStack driver to make it possible to retrieve a single network by using the ID. * [OpenStack] Fix pagination in the list_images() method and make sure method returns all the images, even if the result is spread across multiple pages. * [GCE] Add script for scraping GCE pricing data and improve price addition in _to_node_size method. (GITHUB-1468) [Eis D. Zaster - @Eis-D-Z] * [AWS EC2] Update script for scraping AWS EC2 pricing and update EC2 pricing data. (GITHUB-1469) [Eis D. Zaster - @Eis-D-Z] * [Deployment] Add new wait_period argument to the deploy_node method and default it to 5 seconds. * [Azure ARM] Add script for scraping Azure ARM instance pricing data. (GITHUB-1470) [Eis D. Zaster - @Eis-D-Z] * [Deployment] Make FileDeployment class much faster and more efficient when working with large files or when running multiple FileDeployment steps on a single node. * [Deployment] Add __repr__() and __str__() methods to all the Deployment classes. [Tomaz Muraus - @Kami] * [Deployment] New keep_alive and use_compression arguments have been added to the ParamikoSSHClient class constructor. * [Deployment] Update ParamikoSSHClient.put() method so it returns a correct path when commands are being executed on a Windows machine. * [Outscale] Add a new driver for the Outscale provider. Existing Outscale driver utilizes the EC2 compatible API and this one utilizes native Outscale API. (GITHUB-1476) [Tio Gobin - @tgn-outscale] * [KubeVirt] Add new methods for managing services which allows users to expose ports for the VMs (ex_list_services, ex_create_service, ex_delete_service). (GITHUB-1478) [Eis D. Zaster - @Eis-D-Z] * [LXD] Add new methods for managing network and storage pool capabilities and include other improvements in some of the existing methods. (GITHUB-1477) [Eis D. Zaster - @Eis-D-Z] * [DigitalOcean] Add location argument to the list_sizes() method. * Fix deploy_node() so an exception is not thrown if any of the output (stdout / stderr) produced by the deployment script contains a non-valid utf-8 character. * Add new timeout argument to ScriptDeployment and ScriptFileDeployment class constructor. * [GiG G8] Fix retry functionality when creating port forwards and add support for automatically refresing the JWT auth token inside the connection class if it's about to expire in 60 seconds or less. (GITHUB-1465) [Jo De Boeck - @grimpy] * [Azure ARM] Update create_node so an exception is thrown if user passes ex_use_managed_disks=False, but doesn't provide a value for the ex_storage_account argument. (GITHUB-1448) [@antoinebourayne] * [AWS S3] Make sure driver works correctly for objects with ~ in the name. * [CloudFlare] Update driver to include the whole error chain the thrown exception message field. * [Gandi Live] Don't throw if extra['rrset_ttl'] argument is not passed to the create_record method. (GITHUB-1463) [Tomaz Muraus] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-apache-libcloud?expand=0&rev=103
2020-10-21 03:21:56 +02:00
Version: 3.2.0
Release: 0
Summary: Abstraction over multiple cloud provider APIs
License: Apache-2.0
Group: Development/Languages/Python
URL: https://libcloud.apache.org
Source0: https://files.pythonhosted.org/packages/source/a/apache-libcloud/apache-libcloud-%{version}.tar.gz
Patch1: gce_image_projects.patch
Patch2: ec2_create_node.patch
Patch3: skip-some-tests-for-older-paramiko-versions.patch
BuildRequires: %{python_module libvirt-python}
BuildRequires: %{python_module lockfile}
BuildRequires: %{python_module lxml}
BuildRequires: %{python_module mock}
BuildRequires: %{python_module paramiko}
BuildRequires: %{python_module pytest-runner}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module requests-mock}
BuildRequires: %{python_module setuptools}
- update to 2.7.0: - Test code with Python 3.8 and advertise that we also support Python 3.8. - [OpenStack] Fix OpenStack project scoped token authentication. The driver constructors now accept ``ex_tenant_domain_id`` argument which tells authentication service which domain id to use for the scoped authentication token. (GITHUB-1367) - Introduce type annotations for the base compute API methods. This means you can now leverage mypy to type check (with some limitations) your code which utilizes Libcloud compute API standard API methods. - [Azure ARM] Fix ``attach_volume`` method and allow maximum of 64 disks to be added when LUN is not specified. Previously there was a bug and only a maximum of 63 disks could be added. - New ``start_node`` and ``stop_node`` methods have been added to the base Libcloud compute API NodeDriver class. - [GCE] Add new ``ex_set_volume_labels`` method for managing volume labels to the driver. - [EC2] Add support for new ``inf1.*`` instance types. - [S3] Update S3 driver so a single driver class can be used for different regions. - [S3] Add missing ``eu-north-1`` region to the S3 driver. (GITHUB-1370) - [S3] Add missing regions (eu-west-3, ap-northeast-3, me-south-1) to the driver. - [S3] Update the driver to throw more user-friendly error message if user is using driver for a region X, but trying to upload / download object to / from a region Y. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-apache-libcloud?expand=0&rev=90
2019-12-13 15:27:19 +01:00
BuildRequires: %{python_module typing}
BuildRequires: %{python_module xml}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-lxml
Requires: python-requests
- update to 2.7.0: - Test code with Python 3.8 and advertise that we also support Python 3.8. - [OpenStack] Fix OpenStack project scoped token authentication. The driver constructors now accept ``ex_tenant_domain_id`` argument which tells authentication service which domain id to use for the scoped authentication token. (GITHUB-1367) - Introduce type annotations for the base compute API methods. This means you can now leverage mypy to type check (with some limitations) your code which utilizes Libcloud compute API standard API methods. - [Azure ARM] Fix ``attach_volume`` method and allow maximum of 64 disks to be added when LUN is not specified. Previously there was a bug and only a maximum of 63 disks could be added. - New ``start_node`` and ``stop_node`` methods have been added to the base Libcloud compute API NodeDriver class. - [GCE] Add new ``ex_set_volume_labels`` method for managing volume labels to the driver. - [EC2] Add support for new ``inf1.*`` instance types. - [S3] Update S3 driver so a single driver class can be used for different regions. - [S3] Add missing ``eu-north-1`` region to the S3 driver. (GITHUB-1370) - [S3] Add missing regions (eu-west-3, ap-northeast-3, me-south-1) to the driver. - [S3] Update the driver to throw more user-friendly error message if user is using driver for a region X, but trying to upload / download object to / from a region Y. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-apache-libcloud?expand=0&rev=90
2019-12-13 15:27:19 +01:00
Requires: python-typing
Suggests: python-libvirt-python
Suggests: python-lockfile
Suggests: python-paramiko
Suggests: python-pysphere
BuildArch: noarch
%if %{with python2}
BuildRequires: python-backports.ssl_match_hostname
BuildRequires: python2
Requires: python-backports.ssl_match_hostname
%endif
%python_subpackages
%description
Apache Libcloud is a standard Python library that abstracts away
differences among multiple cloud provider APIs.
%prep
%setup -q -n apache-libcloud-%{version}
%patch1 -p1
%patch2 -p1
%patch3 -p1
sed -i '/^#!/d' demos/gce_demo.py
chmod a-x demos/gce_demo.py
# Setup tests
cp libcloud/test/secrets.py-dist libcloud/test/secrets.py
%build
%python_build
%install
%python_install
find %{buildroot} -name '*.DS_Store' -delete
find %{buildroot} -name '*.json' -size 0 -delete
find %{buildroot} -name '*.pem' -size 0 -delete
%python_expand rm -r %{buildroot}%{$python_sitelib}/libcloud/test
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
# Skip ShellOutSSHClientTests tests which attempt to ssh to localhost
# Note these two extra py3 failures are undesirable and should be fixed
%pytest -k '(not test_consume_stderr_chunk_contains_part_of_multi_byte_utf8_character and not test_consume_stdout_chunk_contains_part_of_multi_byte_utf8_character and not ShellOutSSHClientTests and not ElasticContainerDriverTestCase)'
%files %{python_files}
%license LICENSE
%doc CHANGES.rst README.rst demos/ example_*.py
%{python_sitelib}/*
%changelog