Sophie

Sophie

distrib > Fedora > 18 > x86_64 > by-pkgid > ff24f185f044675482dc24e1fc76c201 > files > 2

igor-0.4.0-1.fc18.src.rpm

Name:      igor
Version:   0.4.0
Release:   1%{?dist}
Summary:   Automated distribution life-cycle testing (daemon)

License:   LGPLv2
Url:       http://www.github.com/fabiand/igor
# curl -L -o %{name}-%{version}.tar.gz https://github.com/fabiand/%{name}/archive/%{version}.tar.gz
Source:   %{name}-%{version}.tar.gz
Group:     Development/Libraries
BuildArch: noarch

BuildRequires: python2-devel
BuildRequires: systemd-units

Requires: %{name}-common = %{version}-%{release}
Requires:  /usr/bin/sudo
Requires:  livecd-tools
Requires:  genisoimage
Requires:  redis, python-redis
Requires(post): systemd
Requires(preun): systemd
Requires(postun): systemd


%description
Igor is a small daemon to continuous automated testing of PXE based Linux
distributions with cobbler, libvirt and real hardware.
It is intended to be combined with Jenkins and to test oVirt Node.


%package common
Summary:   Files shared between Igor daemon and client
Requires:  python-lxml


%description common
A number of files shared between the Igor daemon and client.


%package client
Summary:   Client to communicate with an Igor daemon
Requires:  %{name}-common = %{version}-%{release}
Requires:  firewalld
Requires:  python-fabulous
Requires:  libnotify
Requires:  python-redis


%description client
The client is used to initiate jobs, create profiles etc. and query all sorts
of informations.
Basically it is an CLI to Igor's RESTish API.


%package slave
Summary:          Slave which executes the steps on the target host
Requires(post):   systemd
Requires(preun):  systemd
Requires(postun): systemd


%description slave
The slave is executing the testsuites on the target host.
It is started as a service.


%prep
%setup


%build
%{__python} setup.py build


%install
%{__python} setup.py install --root=%{buildroot}

# Make some scripts executable to silence rpmlint
chmod a+x %{buildroot}/%{python_sitelib}/%{name}/daemon/data/*.sh
chmod a+x %{buildroot}/%{_bindir}/igor-slave


%post
%systemd_post igord.service
%systemd_post igord-event-publisher.service


%post slave
if [ $1 -eq 1 ] ; then
    # Initial installation
    /bin/systemctl daemon-reload >/dev/null 2>&1 || :
    /bin/systemctl enable igor-slave.service >/dev/null 2>&1 || :
fi


%preun
%systemd_preun igord.service
%systemd_preun igord-event-publisher.service


%files
%doc README COPYING
# FIXME add license file (landing with next upstream release)
%config(noreplace) %{_sysconfdir}/igord/igord.cfg.example
%{_sysconfdir}/igord/hook.d/*
%{python_sitelib}/%{name}/daemon
%{python_sitelib}/%{name}*.egg-info
%{_bindir}/igord
%{_unitdir}/igord.service


%files common
%{python_sitelib}/%{name}/__init__.py*
%{python_sitelib}/%{name}/log.py*
%{python_sitelib}/%{name}/common.py*
%{python_sitelib}/%{name}/reports.py*
%{python_sitelib}/%{name}/utils.py*
%{python_sitelib}/%{name}/data


%files client
%{python_sitelib}/%{name}/client
%{_bindir}/igorc


%files slave
%{_bindir}/igor-slave
%{_unitdir}/igor-slave.service


%changelog
* Thu Jul 18 2013 Fabian Deutsch <fabiand@fedoraproject.org> - 0.4.0-1
- Update to latest upstream
- Upstream is now at github
- Introduce common and client subpackages
- Add redis dependency

* Wed Apr 03 2013 Fabian Deutsch <fabiand@fedoraproject.org> - 0.3.0-4
- Drop define, as it was used only in one place

* Wed Apr 03 2013 Fabian Deutsch <fabiand@fedoraproject.org> - 0.3.0-3
- Remove clean
- Specify python version
- Remove CFLAGS in build


* Wed Apr 03 2013 Fabian Deutsch <fabiand@fedoraproject.org> - 0.3.0-2
- Add systemd macros

* Wed Apr 03 2013 Fabian Deutsch <fabiand@fedoraproject.org> - 0.3.0-1
- Initial package