File python-os-refresh-config.spec of Package python-os-refresh-config

#
# spec file for package python-os-refresh-config
#
# Copyright (c) 2024 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/
#


Name:           python3-os-refresh-config
Version:        14.0.0
Release:        0
Summary:        Refresh system configuration
License:        Apache-2.0
Group:          Development/Languages/Python
URL:            https://docs.openstack.org/os-refresh-config
Source0:        https://files.pythonhosted.org/packages/source/o/os-refresh-config/os-refresh-config-14.0.0.tar.gz
BuildRequires:  openstack-macros
BuildRequires:  python3-dib-utils
BuildRequires:  python3-fixtures
BuildRequires:  python3-pbr
BuildRequires:  python3-psutil
BuildRequires:  python3-stestr
BuildRequires:  python3-testscenarios
BuildRequires:  python3-testtools
Requires:       python3-dib-utils
Requires:       python3-pbr
Requires:       python3-psutil
BuildArch:      noarch

%description
Tool to refresh openstack config changes to service.

%prep
%autosetup -n os-refresh-config-14.0.0
%py_req_cleanup

%build
%{py3_build}

%install
%{py3_install}
install -d -m 755 %{buildroot}%{_libexecdir}/os-refresh-config/pre-configure.d
install -d -m 755 %{buildroot}%{_libexecdir}/os-refresh-config/configure.d
install -d -m 755 %{buildroot}%{_libexecdir}/os-refresh-config/migration.d
install -d -m 755 %{buildroot}%{_libexecdir}/os-refresh-config/post-configure.d

%check
# NOTE(jpena): os_refresh_config.py has a wrong shebang, and it is called
# directly by the tests.
sed -i 's/#!\/usr\/bin\/env.*/#!\/usr\/bin\/python3/' os_refresh_config/os_refresh_config.py
%{openstack_stestr_run}

%files
%license LICENSE
%doc README.rst
%{_bindir}/os-refresh-config
%{_bindir}/dib-run-parts
%{python3_sitelib}/os_refresh_config
%{python3_sitelib}/*.egg-info
%{_libexecdir}/os-refresh-config

%changelog
openSUSE Build Service is sponsored by