[pve-devel] r4870 - in pve-manager/pve2: . www/manager

svn-commits at proxmox.com svn-commits at proxmox.com
Mon Jul 5 09:51:28 CEST 2010


Author: dietmar
Date: 2010-07-05 07:51:28 +0000 (Mon, 05 Jul 2010)
New Revision: 4870

Added:
   pve-manager/pve2/www/manager/startup.pl
Modified:
   pve-manager/pve2/ChangeLog
   pve-manager/pve2/www/manager/Makefile.am
Log:


Modified: pve-manager/pve2/ChangeLog
===================================================================
--- pve-manager/pve2/ChangeLog	2010-07-05 07:39:45 UTC (rev 4869)
+++ pve-manager/pve2/ChangeLog	2010-07-05 07:51:28 UTC (rev 4870)
@@ -1,3 +1,8 @@
+2010-07-05  Proxmox Support Team  <support at proxmox.com>
+
+	* www/manager/startup.pl: install startup.pl script to init
+	PVE::Config an logging.
+
 2010-07-02  Proxmox Support Team  <support at proxmox.com>
 
 	* lib/PVE/REST.pm (handler): fix content length

Modified: pve-manager/pve2/www/manager/Makefile.am
===================================================================
--- pve-manager/pve2/www/manager/Makefile.am	2010-07-05 07:39:45 UTC (rev 4869)
+++ pve-manager/pve2/www/manager/Makefile.am	2010-07-05 07:51:28 UTC (rev 4870)
@@ -21,11 +21,16 @@
 pvelib_DATA = pvemanagerlib.js
 pvelibdir = ${WWW_EXTDIR}
 
-manager_DATA = index.pl
+privatedir = ${WWW_BASEDIR}
+private_SCRIPTS = 		\
+	startup.pl
 
 managerdir = ${WWW_ROOTDIR}
+manager_SCRIPTS = 		\
+	index.pl
 
 install-data-hook: 
+	chown -R www-data:www-data ${DESTDIR}/${privatedir}
 	chown -R www-data:www-data ${DESTDIR}/${managerdir}
 	chown -R www-data:www-data ${DESTDIR}/${pvelibdir}
 

Added: pve-manager/pve2/www/manager/startup.pl
===================================================================
--- pve-manager/pve2/www/manager/startup.pl	                        (rev 0)
+++ pve-manager/pve2/www/manager/startup.pl	2010-07-05 07:51:28 UTC (rev 4870)
@@ -0,0 +1,42 @@
+#!/usr/bin/perl -w
+
+use strict;
+
+use PVE::SafeSyslog;
+
+use ModPerl::Util (); #for CORE::GLOBAL::exit
+
+use Apache2::RequestRec ();
+use Apache2::RequestIO ();
+use Apache2::RequestUtil ();
+use Apache2::Access;
+use Apache2::Response;
+use Apache2::Util;
+  
+use Apache2::ServerUtil ();
+use Apache2::Connection ();
+use Apache2::Log ();
+  
+use APR::Table ();
+  
+use ModPerl::Registry ();
+  
+use Apache2::Const -compile => ':common';
+use APR::Const -compile => ':common';
+
+initlog ('proxwww', 'daemon');
+
+use PVE::pvecfg;
+use PVE::REST;
+use PVE::Config;
+
+sub childinit {
+    syslog ('info', "Starting new child $$");
+    PVE::Config::inotify_init();
+}
+
+my $s = Apache2::ServerUtil->server;
+$s->push_handlers(PerlChildInitHandler => \&childinit);
+
+1;
+


Property changes on: pve-manager/pve2/www/manager/startup.pl
___________________________________________________________________
Added: svn:executable
   + *




More information about the pve-devel mailing list