summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Imhof <tantive@gentoo.org>2003-05-20 12:06:32 +0000
committerMichael Imhof <tantive@gentoo.org>2003-05-20 12:06:32 +0000
commitdb7894e00d2813e62bb22a2406513c678b52c720 (patch)
tree17ab75a0189bec8488fe0131516944eaab646988 /app-admin/rackview
parentNew version 'n cleanup (diff)
downloadhistorical-db7894e00d2813e62bb22a2406513c678b52c720.tar.gz
historical-db7894e00d2813e62bb22a2406513c678b52c720.tar.bz2
historical-db7894e00d2813e62bb22a2406513c678b52c720.zip
Unmasked. Closes #20876.
Diffstat (limited to 'app-admin/rackview')
-rw-r--r--app-admin/rackview/ChangeLog8
-rw-r--r--app-admin/rackview/files/digest-rackview-0.04-r11
-rw-r--r--app-admin/rackview/rackview-0.04-r1.ebuild91
3 files changed, 99 insertions, 1 deletions
diff --git a/app-admin/rackview/ChangeLog b/app-admin/rackview/ChangeLog
index d8c951df1c0e..1cc7e7576583 100644
--- a/app-admin/rackview/ChangeLog
+++ b/app-admin/rackview/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for app-admin/rackview
# Copyright 2000-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/rackview/ChangeLog,v 1.1 2003/05/16 21:14:41 tantive Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/rackview/ChangeLog,v 1.2 2003/05/20 12:06:32 tantive Exp $
+
+*rackview-0.04-r1 (20 May 2003)
+
+ 20 May 2003; <tantive@gentoo.org> rackview-0.04-r1.ebuild:
+ Some changes to ensure all paths are set correct.
+ Submitted by Rigo Ketelings <rigo@home.nl>.
*rackview-0.04 (16 May 2003)
diff --git a/app-admin/rackview/files/digest-rackview-0.04-r1 b/app-admin/rackview/files/digest-rackview-0.04-r1
new file mode 100644
index 000000000000..b0d943e4399c
--- /dev/null
+++ b/app-admin/rackview/files/digest-rackview-0.04-r1
@@ -0,0 +1 @@
+MD5 eb88fa354f7c18c0ec1dcb84fe4098a6 rackview-0.04.tar.gz 1031514
diff --git a/app-admin/rackview/rackview-0.04-r1.ebuild b/app-admin/rackview/rackview-0.04-r1.ebuild
new file mode 100644
index 000000000000..f895f7741e66
--- /dev/null
+++ b/app-admin/rackview/rackview-0.04-r1.ebuild
@@ -0,0 +1,91 @@
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /home/cvsroot/gentoo-x86
+
+inherit perl-module
+
+DESCRIPTION="rackview is a tool for visualizing the layout of rack-mounted equipment. The purpose of this tool is to assist in planning and tracking of hardware changes to racks in a data center, and to provide a host-oriented interface into other database tools."
+SRC_URI="mirror://sourceforge/rackview/rackview-${PV}.tar.gz"
+HOMEPAGE="http://rackview.sf.net"
+
+SLOT="0"
+KEYWORDS="x86"
+LICENSE="Artistic"
+IUSE="apache2 mysql"
+DEPEND="dev-lang/perl
+ dev-perl/GD
+ dev-perl/DBI
+ mysql? ( dev-db/mysql )"
+DOCS="ChangeLog COPYING README* doc/*"
+
+#In case of Apache
+
+use apache2 || HTTPD_ROOT="`grep '^DocumentRoot' /etc/apache/conf/apache.conf | cut -d\ -f2`" \
+ || HTTPD_USER="`grep '^User' /etc/apache/conf/commonapache.conf | cut -d \ -f2`" \
+ || HTTPD_GROUP="`grep '^Group' /etc/apache/conf/commonapache.conf | cut -d \ -f2`"
+
+#In case of Apache2
+
+use apache2 && HTTPD_ROOT="`grep '^DocumentRoot' /etc/apache2/conf/apache2.conf | cut -d\ -f2`" \
+ && HTTPD_USER="`grep '^User' /etc/apache2/conf/commonapache2.conf | cut -d \ -f2`" \
+ && HTTPD_GROUP="`grep '^Group' /etc/apache2/conf/commonapache2.conf | cut -d \ -f2`"
+
+# Else use defaults
+
+[ -z "${HTTPD_ROOT}" ] && HTTPD_ROOT="/home/httpd/htdocs"
+[ -z "${HTTPD_USER}" ] && HTTPD_USER="apache"
+[ -z "${HTTPD_GROUP}" ] && HTTPD_GROUP="apache"
+
+src_install() {
+
+ perl-module_src_install
+
+ dodoc ${DOCS}
+
+ #Correct configfile
+ dodir /etc/${PN}
+ mv ${D}usr/etc/eidetic/* ${D}etc/${PN}
+ cd ${D}etc/${PN}
+ cp rackview.conf ${PN}.conf.orig \
+ && sed -e "s:eidetic:${PN}:" ${PN}.conf.orig > ${PN}.conf2.orig \
+ && sed -e "s:/home/www/site_html/images:${HTTPD_ROOT}:" ${PN}.conf2.orig > ${PN}.conf3.orig \
+ && sed -e "s:images/rack_images:rack_images:" ${PN}.conf3.orig > ${PN}.conf \
+ && rm *.orig \
+ || ewarn "Please check /etc/${PN}/${PN}.conf"
+ rm -fr ${D}usr/etc #Remove trash
+
+ einfo "Installing example in ${HTTPD_ROOT}/${PN}"
+ cd ${S}
+ dodir ${HTTPD_ROOT}/${PN}
+ mv example/* ${D}${HTTPD_ROOT}/${PN}
+ mv ${D}usr/var/www/html/* ${D}${HTTPD_ROOT}
+ rm -fr ${D}usr/var #Remove trash
+
+ #Install .cgi
+ dodir ${HTTPD_ROOT}/../cgi-bin
+ cp cgi-bin/rackview.cgi ${D}${HTTPD_ROOT}/../cgi-bin/${PN}.cgi.orig \
+ && cd ${D}${HTTPD_ROOT}/../cgi-bin \
+ && sed -e "s:/var/www/html:${HTTPD_ROOT}:" \
+ -e "s:eidetic:${PN}:" ${PN}.cgi.orig > ${PN}.cgi \
+ && chmod u+x ${PN}.cgi \
+ && rm ${PN}.cgi.orig \
+ || ewarn "Please copy (& check) ${PN}.cgi manually."
+
+ #Script needs to change also
+ cd ${D}usr/bin
+ cp erackview erackview.orig \
+ && sed -e "s:eidetic:${PN}:" erackview.orig > e${PN} \
+ && chmod ugo+x e${PN} \
+ && rm erackview.orig \
+ || ewarn "Please check script 'e${PN}'."
+
+ #Making sure HTTPD_USER owns all files
+ cd ${D}
+ chown -R ${HTTPD_USER}:${HTTPD_GROUP} * || ewarn "Check if ${HTTPD_USER} owns all files."
+}
+
+pkg_postinst() {
+ use mysql && einfo "To load data from mysql, change 'dat' in 'db' in /etc/${PN}/${PN}.conf" \
+ && einfo "SQL files for creating these tables are available in ${S}/sql"
+ einfo "Now go to http://${HOSTNAME}/${PN}/ to test."
+}