Initial specs for dib-utils and os-refresh-config

They have been traditionally pulled in as dependencies, but they
are actually OpenStack projects.

Change-Id: I2b4227d583883c10f9baa64973374cf868bfe75a
This commit is contained in:
Javier Pena
2018-08-07 17:35:23 +02:00
parent 78876000b3
commit e3c7e35a3a
2 changed files with 96 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
%global sname dib-utils
Name: {{ py2name('dib-utils') }}
Version: 0.0.11
Release: 0
Summary: Pieces of diskimage-builder that are useful standalone
License: {{ license('Apache-2.0') }}
Group: Development/Languages/Python
URL: https://launchpad.net/%{sname}
Source0: https://tarballs.openstack.org//%{sname}/%{sname}-%{version}.tar.gz
BuildRequires: openstack-macros
BuildRequires: {{ py2pkg('d2to1') }}
BuildRequires: {{ py2pkg('devel') }}
BuildRequires: {{ py2pkg('pbr') }}
BuildArch: noarch
%description
Pieces of diskimage-builder that are useful standalone.
This allows them to be used without pulling in all of
diskimage-builder and its dependencies.
%prep
%autosetup -n %{sname}-%{version}
%py_req_cleanup
sed -i 's/^warning-is-error.*/warning-is-error = 0/g' setup.cfg
%build
%py2_build
%install
%py2_install
%check
tests/run_tests.sh
%files
%license LICENSE
%doc README.md
%{_bindir}/dib-run-parts
%{python2_sitelib}/*.egg-info
%changelog

View File

@@ -0,0 +1,55 @@
%global sname os-refresh-config
Name: {{ py2name('os-refresh-config') }}
Version: 9.0.0
Release: 0
Summary: Refresh system configuration
License: {{ license('Apache-2.0') }}
Group: Development/Languages/Python
URL: https://launchpad.net/%{sname}
Source0: https://files.pythonhosted.org/packages/source/o/%{sname}/%{sname}-%{version}.tar.gz
BuildRequires: openstack-macros
BuildRequires: {{ py2pkg('devel') }}
BuildRequires: {{ py2pkg('dib-utils') }}
BuildRequires: {{ py2pkg('fixtures') }}
BuildRequires: {{ py2pkg('mock') }}
BuildRequires: {{ py2pkg('pbr') }}
BuildRequires: {{ py2pkg('psutil') }}
BuildRequires: {{ py2pkg('setuptools') }}
BuildRequires: {{ py2pkg('testrepository') }}
BuildRequires: {{ py2pkg('testscenarios') }}
BuildRequires: {{ py2pkg('testtools') }}
Requires: {{ py2pkg('dib-utils') }}
Requires: {{ py2pkg('pbr') }}
Requires: {{ py2pkg('psutil') }}
BuildArch: noarch
%description
Tool to refresh openstack config changes to service.
%prep
%autosetup -n %{sname}-%{version}
%py_req_cleanup
sed -i 's/^warning-is-error.*/warning-is-error = 0/g' setup.cfg
%build
%py2_build
%install
%py2_install
install -d -m 755 %{buildroot}%{_libexecdir}/%{name}/pre-configure.d
install -d -m 755 %{buildroot}%{_libexecdir}/%{name}/configure.d
install -d -m 755 %{buildroot}%{_libexecdir}/%{name}/migration.d
install -d -m 755 %{buildroot}%{_libexecdir}/%{name}/post-configure.d
%check
%{__python2} setup.py testr
%files
%license LICENSE
%doc README.rst
%{_bindir}/os-refresh-config
%{python2_sitelib}/os_refresh_config
%{python2_sitelib}/*.egg-info
%{_libexecdir}/%{name}
%changelog