summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile5
-rw-r--r--rteval.spec32
-rwxr-xr-xserver/gen_config.sh13
-rwxr-xr-xserver/install.sh12
4 files changed, 48 insertions, 14 deletions
diff --git a/Makefile b/Makefile
index 5bab542..7f0551b 100644
--- a/Makefile
+++ b/Makefile
@@ -20,10 +20,13 @@ install:
python setup.py --dry-run install
tarfile:
- rm -rf tarball && mkdir -p tarball/rteval-$(VERSION)
+ rm -rf tarball && mkdir -p tarball/rteval-$(VERSION) tarball/rteval-$(VERSION)/server
cp -r rteval tarball/rteval-$(VERSION)
cp -r doc/ tarball/rteval-$(VERSION)
cp Makefile setup.py rteval.spec COPYING tarball/rteval-$(VERSION)
+ cp server/database.py server/rtevaldb.py server/rteval_xmlrpc.py server/xmlrpc_API1.py tarball/rteval-$(VERSION)/server
+ cp server/apache-rteval.conf.tpl server/gen_config.sh tarball/rteval-$(VERSION)/server
+ cp server/README tarball/rteval-$(VERSION)/README.xmlrpc
tar -C tarball -cjvf rteval-$(VERSION).tar.bz2 rteval-$(VERSION)
rpm: tarfile
diff --git a/rteval.spec b/rteval.spec
index 98fc88c..3d6ec01 100644
--- a/rteval.spec
+++ b/rteval.spec
@@ -3,7 +3,7 @@
Name: rteval
Version: 1.7
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: Utility to evaluate system suitability for RT Linux
Group: Development/Tools
@@ -29,11 +29,19 @@ the cyclictest program is run to measure event response time. After
the run time completes, a statistical analysis of the event response
times is done and printed to the screen.
+%package xmlrpc
+Summary: XML-RPC server based on mod_python for receving reports from rteval
+Requires: postgresql httpd mod_python
+
+%description xmlrpc
+This package requires Apache, mod_python and a PostgreSQL server. It will
+enable an XML-RPC interface for the rteval program to submit the reports to
+a central server.
+
%prep
%setup -q
-
# version sanity check (make sure specfile and rteval.py match)
srcver=$(awk '/version =/ { print $3; }' rteval/rteval.py | sed -e 's/"\(.*\)"/\1/')
if [ $srcver != %{version} ]; then
@@ -63,6 +71,17 @@ install -m 644 doc/rteval.8 ${RPM_BUILD_ROOT}/%{_mandir}/man8/
chmod 755 ${RPM_BUILD_ROOT}/%{python_sitelib}/rteval/rteval.py
ln -fs %{python_sitelib}/rteval/rteval.py ${RPM_BUILD_ROOT}/%{_bindir}/rteval
+# XML-RPC server install
+cd server
+mkdir -p ${RPM_BUILD_ROOT}/var/www/html/rteval/API1
+install -m 644 rteval_xmlrpc.py ${RPM_BUILD_ROOT}/var/www/html/rteval/API1
+install -m 644 xmlrpc_API1.py ${RPM_BUILD_ROOT}/var/www/html/rteval/API1
+install -m 644 rtevaldb.py ${RPM_BUILD_ROOT}/var/www/html/rteval/API1
+install -m 644 database.py ${RPM_BUILD_ROOT}/var/www/html/rteval/API1
+mkdir -p ${RPM_BUILD_ROOT}/etc/httpd/conf.d/
+./gen_config.sh %{_localstatedir}/www/html/rteval/API1
+install -m 644 apache-rteval.conf ${RPM_BUILD_ROOT}%{_sysconfdir}/httpd/conf.d/rteval-xmlrpc.conf
+cd ..
%clean
rm -rf $RPM_BUILD_ROOT
@@ -85,8 +104,17 @@ rm -rf $RPM_BUILD_ROOT
%{python_sitelib}/rteval/
%{_bindir}/rteval
+%files xmlrpc
+%defattr(-,root,root,-)
+%doc README.xmlrpc
+%config(noreplace) %{_sysconfdir}/httpd/conf.d/rteval-xmlrpc.conf
+%{_localstatedir}/www/html/rteval/
+
%changelog
+* Mon Oct 26 2009 David Sommerseth <davids@redhat.com> - 1.7-2
+- Added xmlrpc package, containing the XML-RPC mod_python modules
+
* Tue Oct 13 2009 Clark Williams <williams@redhat.com> - 1.7-1
- added kthread status to xml file
- merged davids changes for option processing and additions
diff --git a/server/gen_config.sh b/server/gen_config.sh
new file mode 100755
index 0000000..4b57353
--- /dev/null
+++ b/server/gen_config.sh
@@ -0,0 +1,13 @@
+#/bin/sh
+
+APACHECONF="apache-rteval.conf"
+INSTALLDIR="$1"
+
+echo "Creating Apache config file: apache-rteval.conf"
+escinstpath="$(echo ${INSTALLDIR} | sed -e 's/\//\\\\\//g')"
+expr=$(echo "s/{_INSTALLDIR_}/${escinstpath}/")
+eval "sed -e ${expr} ${APACHECONF}.tpl" > ${APACHECONF}
+echo "Copy the apache apache-rteval.conf into your Apache configuration"
+echo "directory and restart your web server"
+echo
+
diff --git a/server/install.sh b/server/install.sh
index 7d2b863..5f67948 100755
--- a/server/install.sh
+++ b/server/install.sh
@@ -5,9 +5,6 @@ XSLT_FILES="parser/xmlparser.xsl"
XSLTDIR="/usr/share/rteval"
-APACHECONF="apache-rteval.conf"
-
-
if [ $# != 1 ]; then
echo "$0 </var/www/html/.... full path to the directory the XML-RPC server will reside>"
exit
@@ -23,11 +20,4 @@ echo "Installing XSLT templates to ${XSLTDIR}"
cp -v ${XSLT_FILES} ${XSLTDIR}
echo
-echo "Creating Apache config file: apache-rteval.conf"
-escinstpath="$(echo ${INSTALLDIR} | sed -e 's/\//\\\\\//g')"
-expr=$(echo "s/{_INSTALLDIR_}/${escinstpath}/")
-eval "sed -e ${expr} ${APACHECONF}.tpl" > ${APACHECONF}
-echo "Copy the apache apache-rteval.conf into your Apache configuration"
-echo "directory and restart your web server"
-echo
-
+./gen_config.sh ${INSTALLDIR}