5a6752e
%global htmldir /var/www/yawn
5a6752e
%global apacheconfdir /etc/httpd
e7e77d0
%global svnrev 588
5a6752e
5a6752e
Name:           yawn
5a6752e
Version:        0
e7e77d0
Release:        0.7.20120905svn%{svnrev}%{?dist}
5a6752e
Summary:        Yet Another WBEM Navigator
5a6752e
5a6752e
5a6752e
Group:          Applications/System
5a6752e
License:        GPLv2
5a6752e
URL:            https://sourceforge.net/apps/mediawiki/pywbem/index.php?title=YAWN
ddf0e26
# The source for this package was pulled from upstream svn repository.
ddf0e26
# Use the following commands to get the archive:
ddf0e26
#  svn export https://pywbem.svn.sourceforge.net/svnroot/pywbem/yawn/trunk/mod_wsgi yawn-0
ddf0e26
#  tar czvf yawn-0.tar.gz yawn-0/
ddf0e26
Source0:        %{name}-%{version}.tar.gz
ddf0e26
ddf0e26
BuildRequires:  httpd, python-setuptools
20d8c0c
Requires:       mod_wsgi, pywbem, httpd, python-werkzeug, python-mako
5a6752e
BuildArch:      noarch
5a6752e
5a6752e
%description
5a6752e
Web-based CIM/WBEM browser
5a6752e
ddf0e26
%package server
ddf0e26
Summary: Standalone web server for yawn
ddf0e26
Requires: %{name}
ddf0e26
ddf0e26
%description server
ddf0e26
Script to run yawn without Apache web server.
ddf0e26
5a6752e
%prep
ddf0e26
%setup -q
5a6752e
5a6752e
%build
ddf0e26
%{__python} setup.py build
5a6752e
5a6752e
%install
5a6752e
rm -rf $RPM_BUILD_ROOT
ddf0e26
%{__python} setup.py install --skip-build --root ${RPM_BUILD_ROOT}
5a6752e
mkdir -p $RPM_BUILD_ROOT%{htmldir}
ddf0e26
install ./scripts/yawn.wsgi $RPM_BUILD_ROOT%{htmldir}/index.wsgi
5a6752e
install -d $RPM_BUILD_ROOT%{apacheconfdir}/conf.d/
ddf0e26
install -m 0644 ./apache/yawn.conf ${RPM_BUILD_ROOT}/%{apacheconfdir}/conf.d/yawn.conf
5a6752e
5a6752e
%clean
5a6752e
rm -rf $RPM_BUILD_ROOT
5a6752e
5a6752e
%post 
5a6752e
/bin/systemctl try-restart httpd.service >/dev/null 2>&1 || :
5a6752e
5a6752e
%files
5a6752e
%defattr(-,root,root,-)
5a6752e
%{htmldir}
ddf0e26
%{python_sitelib}/*
5a6752e
%config(noreplace) %{apacheconfdir}/conf.d/yawn.conf
5a6752e
ddf0e26
%files server
ddf0e26
%{_bindir}/yawn.py
ddf0e26
5a6752e
%changelog
e7e77d0
* Wed Sep 05 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.8.20120905svn588
e7e77d0
- Update to latest upstream version
e7e77d0
20d8c0c
* Thu Aug 02 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.7.20120620svn578
20d8c0c
- Add python-mako to Requires
20d8c0c
c633ae6
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0-0.6.20120620svn578
c633ae6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
c633ae6
ddf0e26
* Mon Jul 02 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.5.20120620svn578
ddf0e26
- Update to latest upstream version (switched from mod_python to mod_wsgi)
ddf0e26
a44724f
* Thu May 17 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.4.20120227svn561
a44724f
- Fix URLs (patch by Radek Novacek, rnovacek@redhat.com)
a44724f
dc9823a
* Tue Mar 13 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.3.20120227svn561
dc9823a
- Fix Pickle method sets Content-type: text/plain instead of text/html
dc9823a
  (patch by Jan Safranek, jsafrane@redhat.com)
dc9823a
  Resolves: #802683
dc9823a
5a6752e
* Tue Feb 28 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.2.20120227svn561
5a6752e
- Fix twice listed files
5a6752e
5a6752e
* Mon Feb 27 2012 Vitezslav Crhonek <vcrhonek@redhat.com> - 0-0.1.20120227svn561
5a6752e
- Remove obsolete BuildRoot tag, use systemctl instead of service, own htmldir,
5a6752e
  fix source and version
5a6752e
5a6752e
* Thu Feb 23 2012 Vitezslav Crhonek <vcrhonek@redhat.com>
5a6752e
- Change htmldir, fix license
5a6752e
5a6752e
* Wed Jan 25 2012 Vitezslav Crhonek <vcrhonek@redhat.com>
5a6752e
- Initial build for Fedora