File openstack-neutron-fwaas.spec of Package openstack-neutron-fwaas-doc

# spec file
# Copyright (c) 2023 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

%define component neutron-fwaas

%define version_unconverted 13.0.3.dev4

Name:           openstack-%{component}
Version:        13.0.3~dev4
Release:        0
Summary:        OpenStack Network - firewall as a service
License:        Apache-2.0
Group:          System/Management
Source99:       rpmlintrc
BuildRequires:  crudini
BuildRequires:  fdupes
BuildRequires:  openstack-neutron
BuildRequires:  openstack-suse-macros
BuildRequires:  python-devel
BuildRequires:  python-pbr
# Documentation build requirements:
BuildRequires:  python-Sphinx
BuildRequires:  python-oslosphinx
# Test requirements
BuildRequires:  python-WebTest >= 2.0
BuildRequires:  python-cliff >= 1.10.0
BuildRequires:  python-fixtures >= 0.3.14
BuildRequires:  python-mock >= 1.0
BuildRequires:  python-neutron-lib
BuildRequires:  python-openstackdocstheme
BuildRequires:  python-oslo.config
BuildRequires:  python-oslotest >= 1.5.1
BuildRequires:  python-psycopg2
BuildRequires:  python-python-subunit >= 0.0.18
BuildRequires:  python-requests-mock >= 0.6.0
BuildRequires:  python-testrepository >= 0.0.18
BuildRequires:  python-testscenarios >= 0.4
BuildRequires:  python-testtools >= 0.9.36
Requires:       openstack-neutron
Requires:       python
Requires:       python >= 2.7
Requires:       python-neutron-fwaas = %{version}
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

Neutron is a virtual network service for Openstack.

Just like OpenStack Nova provides an API to dynamically request and
configure virtual servers, Neutron provides an API to dynamically
request and configure virtual networks. These networks connect
"interfaces" from other OpenStack services (e.g., vNICs from Nova VMs).
The Neutron API supports extensions to provide advanced network
capabilities (e.g., QoS, ACLs, network monitoring, etc)

This package contains the firewall as as service (fwaas) component for Neutron.

%package -n python-%{component}
Summary:        OpenStack Network fwaas - Python module
Group:          Development/Languages/Python
Requires:       python >= 2.7
Requires:       python-SQLAlchemy >= 1.0.10
Requires:       python-alembic >= 0.8.10
Requires:       python-eventlet >= 0.18.2
Requires:       python-httplib2 >= 0.7.5
Requires:       python-netaddr >= 0.7.18
Requires:       python-neutron-lib >= 1.18.0
Requires:       python-oslo.concurrency >= 3.26.0
Requires:       python-oslo.config >= 5.2.0
Requires:       python-oslo.db >= 4.27.0
Requires:       python-oslo.log >= 3.36.0
Requires:       python-oslo.messaging >= 5.29.0
Requires:       python-oslo.privsep >= 1.23.0
Requires:       python-oslo.serialization >= 1.10.0
Requires:       python-oslo.service >= 1.24.0
Requires:       python-oslo.utils >= 3.33.0
Requires:       python-pbr >= 2.0.0
Requires:       python-pyroute2 >= 0.4.21
Requires:       python-six >= 1.10.0

%description -n python-%{component}
This package contains the core Python module of OpenStack Neutron fwaas

%package test
Summary:        OpenStack Network fwaas - Testsuite
Group:          Development/Languages/Python
Requires:       %{name} = %{version}
Requires:       python-WebOb >= 1.7.1
Requires:       python-testresources >= 2.0.0

%description test
The OpenStack Neutron fwaas testsuite. It is used to verify the functionality
of OpenStack Neutron.

%setup -q -n %{component}-%{version_unconverted}


python build
#python build_sphinx -b man

for x in `ls etc/oslo-config-generator/*`; do
    PYTHONPATH=. oslo-config-generator --config-file $x

python install --skip-build --prefix=%{_prefix} --root=%{buildroot} --install-data=/

### configuration files
install -p -D -m 644 etc/fwaas_driver.ini.sample %{buildroot}%{_sysconfdir}/neutron/fwaas_driver.ini

## SUSE configuration defaults
crudini --set %{buildroot}/etc/neutron/fwaas_driver.ini fwaas driver
crudini --set %{buildroot}/etc/neutron/fwaas_driver.ini fwaas enabled True

### misc
%fdupes %{buildroot}%{python_sitelib}/neutron_fwaas

testr init
#testr list-tests

%doc README.rst
%license LICENSE
%config(noreplace) %{_sysconfdir}/neutron/fwaas_driver.ini
%config(noreplace) %{_sysconfdir}/neutron/rootwrap.d/fwaas-privsep.filters

%files -n python-%{component}
%license LICENSE
# tempest test must be in python-neutron (because of entry point)
%exclude %{python_sitelib}/neutron_fwaas/tests/contrib
%exclude %{python_sitelib}/neutron_fwaas/tests/etc
%exclude %{python_sitelib}/neutron_fwaas/tests/fullstack
%exclude %{python_sitelib}/neutron_fwaas/tests/functional
%exclude %{python_sitelib}/neutron_fwaas/tests/unit

%files test
%license LICENSE
%exclude %{python_sitelib}/neutron_fwaas/tests/tempest_plugin

openSUSE Build Service is sponsored by