[Pkg-zenoss-commits] r113 - in /packages/zenoss/trunk/debian: patches/remove-ZENHOME-shellscripts.dpatch zenoss.postinst

bzed-guest at users.alioth.debian.org bzed-guest at users.alioth.debian.org
Fri Jun 15 20:18:09 UTC 2007


Author: bzed-guest
Date: Fri Jun 15 20:18:08 2007
New Revision: 113

URL: http://svn.debian.org/wsvn/pkg-zenoss/?sc=1&rev=113
Log:
postinst + patch update

Modified:
    packages/zenoss/trunk/debian/patches/remove-ZENHOME-shellscripts.dpatch
    packages/zenoss/trunk/debian/zenoss.postinst

Modified: packages/zenoss/trunk/debian/patches/remove-ZENHOME-shellscripts.dpatch
URL: http://svn.debian.org/wsvn/pkg-zenoss/packages/zenoss/trunk/debian/patches/remove-ZENHOME-shellscripts.dpatch?rev=113&op=diff
==============================================================================
--- packages/zenoss/trunk/debian/patches/remove-ZENHOME-shellscripts.dpatch (original)
+++ packages/zenoss/trunk/debian/patches/remove-ZENHOME-shellscripts.dpatch Fri Jun 15 20:18:08 2007
@@ -2,7 +2,7 @@
 ## remove-ZENHOME-shellscripts.dpatch by  <bernd at bzed.de>
 ##
 ## DP: more workarounds for $ZENHOME
-## DP: grep -lr \$ZENHOME * | grep -v debian/ | grep -v zendocs | grep -v inst | while read i; do  sed "s,\$ZENHOME,\$\(getent passwd |grep '^zenoss' | cut -d : -f 6\),g" $i > $i.new; mv $i.new $i; done && grep -lr \${ZENHOME} * | grep -v debian/ | grep -v zendocs | grep -v inst | while read i; do  sed "s,\${ZENHOME},\$\(getent passwd |grep '^zenoss' | cut -d : -f 6\),g" $i > $i.new; mv $i.new $i; done
+## DP: grep -lr \$ZENHOME * | grep -v debian/ | grep -v zendocs | grep -v inst | while read i; do  sed "s,\$ZENHOME,\$\(getent passwd zenoss | cut -d : -f 6\),g" $i > $i.new; mv $i.new $i; done && grep -lr \${ZENHOME} * | grep -v debian/ | grep -v zendocs | grep -v inst | while read i; do  sed "s,\${ZENHOME},\$\(getent passwd zenoss | cut -d : -f 6\),g" $i > $i.new; mv $i.new $i; done
 
 @DPATCH@
 diff -urNad zenoss~/Products/ZenUtils/Graphics.py zenoss/Products/ZenUtils/Graphics.py
@@ -13,7 +13,7 @@
          config = os.path.join(os.environ['ZENHOME'], 'lib/graphviz/config')
          if not os.path.exists(config) or os.path.getsize(config) == 0:
 -            os.system("$ZENHOME/bin/dot -c")
-+            os.system("$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/dot -c")
++            os.system("$(getent passwd zenoss | cut -d : -f 6)/bin/dot -c")
          import pydot
          graph = pydot.graph_from_edges(edges, directed=directed)
          graph.ranksep = '1.5'
@@ -25,7 +25,7 @@
                                 help='File to backup to.'
                                       ' Backups will by default be placed'
 -                                     ' in $ZENHOME/backups/')
-+                                     ' in $(getent passwd |grep '^zenoss' | cut -d : -f 6)/backups/')
++                                     ' in $(getent passwd zenoss | cut -d : -f 6)/backups/')
          self.parser.add_option('--no-eventsdb',
                                 dest="noEventsDb",
                                 default=False,
@@ -37,7 +37,7 @@
      def getRepozoPath(self):
          ''' Return path to repozo.py
 -        This is usually $ZENHOME/bin/repozo.py, but on the appliance it is
-+        This is usually $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/repozo.py, but on the appliance it is
++        This is usually $(getent passwd zenoss | cut -d : -f 6)/bin/repozo.py, but on the appliance it is
          $ZOPEHOME/bin/repozo.py
          '''
          path = os.path.join(self.zenhome, 'bin', 'repozo.py')
@@ -49,7 +49,7 @@
          # Continue without copying if the srcDir is already in Products
          if os.path.exists(root) and os.path.samefile(root, srcDir):
 -            self.log.debug('Directory already in $ZENHOME/Products,'
-+            self.log.debug('Directory already in $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products,'
++            self.log.debug('Directory already in $(getent passwd zenoss | cut -d : -f 6)/Products,'
                              ' not copying.')
              return packName
          
@@ -59,11 +59,11 @@
          self.log.debug('Copying %s' % packName)
 -        #result = os.system('cp -r %s $ZENHOME/Products/' % srcDir)
 -        result = os.system('rsync -rlC %s $ZENHOME/Products' % srcDir)
-+        #result = os.system('cp -r %s $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/' % srcDir)
-+        result = os.system('rsync -rlC %s $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products' % srcDir)
++        #result = os.system('cp -r %s $(getent passwd zenoss | cut -d : -f 6)/Products/' % srcDir)
++        result = os.system('rsync -rlC %s $(getent passwd zenoss | cut -d : -f 6)/Products' % srcDir)
          if result == -1:
 -            self.stop('Error copying %s to $ZENHOME/Products' % srcDir)
-+            self.stop('Error copying %s to $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products' % srcDir)
++            self.stop('Error copying %s to $(getent passwd zenoss | cut -d : -f 6)/Products' % srcDir)
          
          return packName
          
@@ -75,10 +75,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/lib/python/ZODB
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/lib/python/ZODB
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/lib/python/ZODB
  PRGNAME=fsrecover.py
  
  PIDFILE=$VARDIR/ZEO_SERVER.pid
@@ -90,10 +90,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenEvents
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenEvents
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenEvents
  PRGNAME=zenactions.py
  CFGFILE=$CFGDIR/zenactions.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -106,8 +106,8 @@
  
 -. $ZENHOME/bin/zenfunctions
 -$PYTHON $ZENHOME/Products/ZenUtils/ZenBackup.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenUtils/ZenBackup.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenUtils/ZenBackup.py "$CMD" $*
 diff -urNad zenoss~/bin/zenbatchload zenoss/bin/zenbatchload
 --- zenoss~/bin/zenbatchload	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenbatchload	2007-06-15 16:14:03.000000000 +0100
@@ -117,8 +117,8 @@
  
 -. $ZENHOME/bin/zenfunctions
 -$PYTHON $ZENHOME/Products/ZenModel/BatchDeviceLoader.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenModel/BatchDeviceLoader.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenModel/BatchDeviceLoader.py "$CMD" $*
 diff -urNad zenoss~/bin/zenbuild zenoss/bin/zenbuild
 --- zenoss~/bin/zenbuild	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenbuild	2007-06-15 16:14:03.000000000 +0100
@@ -127,10 +127,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -$PYTHON $ZENHOME/Products/ZenModel/zenbuild.py "$CMD" "$@"
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenModel/zenbuild.py "$CMD" "$@"
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenModel/zenbuild.py "$CMD" "$@"
  
 diff -urNad zenoss~/bin/zenchkrels zenoss/bin/zenchkrels
 --- zenoss~/bin/zenchkrels	2007-04-26 19:57:02.000000000 +0100
@@ -141,8 +141,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenUtils/CheckRelations.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenUtils/CheckRelations.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenUtils/CheckRelations.py "$CMD" $*
 diff -urNad zenoss~/bin/zenchkschema zenoss/bin/zenchkschema
 --- zenoss~/bin/zenchkschema	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenchkschema	2007-06-15 16:14:03.000000000 +0100
@@ -152,8 +152,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenRelations/checkrel.py $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRelations/checkrel.py $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRelations/checkrel.py $*
 diff -urNad zenoss~/bin/zencommand zenoss/bin/zencommand
 --- zenoss~/bin/zencommand	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zencommand	2007-06-15 16:14:03.000000000 +0100
@@ -162,10 +162,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenRRD
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRRD
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenRRD
  PRGNAME=zencommand.py
  CFGFILE=$CFGDIR/zencommand.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -177,7 +177,7 @@
  #
  # Most of the time this script simply delegates to
 -# ${ZENHOME}/bin/zenoss to actually execute the requested command
-+# $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenoss to actually execute the requested command
++# $(getent passwd zenoss | cut -d : -f 6)/bin/zenoss to actually execute the requested command
  # (start/stop).  But, in some situations it behaves differently.  
  #
  # This script also checks for the fresh_install or upgraded flags.  If
@@ -186,11 +186,11 @@
  # signature of zenoss having been installed for the first time (but
  # not configured yet)
 -export FRESH_INSTALL=${ZENHOME}/.fresh_install
-+export FRESH_INSTALL=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/.fresh_install
++export FRESH_INSTALL=$(getent passwd zenoss | cut -d : -f 6)/.fresh_install
  
  # signature of zenoss having been upgraded from a previous install
 -export UPGRADED=${ZENHOME}/.upgraded
-+export UPGRADED=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/.upgraded
++export UPGRADED=$(getent passwd zenoss | cut -d : -f 6)/.upgraded
  
  
  # changes the owners and permissions for the zenoss files
@@ -199,9 +199,9 @@
 -        ${ZENHOME}/log \
 -        ${ZENHOME}/etc \
 -        ${ZENHOME}/var
-+        $(getent passwd |grep '^zenoss' | cut -d : -f 6)/log \
-+        $(getent passwd |grep '^zenoss' | cut -d : -f 6)/etc \
-+        $(getent passwd |grep '^zenoss' | cut -d : -f 6)/var
++        $(getent passwd zenoss | cut -d : -f 6)/log \
++        $(getent passwd zenoss | cut -d : -f 6)/etc \
++        $(getent passwd zenoss | cut -d : -f 6)/var
      do
          if [ ! -d ${dir} ]; then
              continue
@@ -210,7 +210,7 @@
  
      # location of where we copy configuration items to
 -    ZEN_ETC=${ZENHOME}/etc
-+    ZEN_ETC=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/etc
++    ZEN_ETC=$(getent passwd zenoss | cut -d : -f 6)/etc
  
      # update the snmpd.conf file
      SNMPD_CONF_DIR=`dirname ${SNMPD_CONF}`
@@ -219,7 +219,7 @@
      # run the first time initialization pre-run script
      set_perms
 -    ${ZENHOME}/bin/zenoss_init_pre
-+    $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenoss_init_pre
++    $(getent passwd zenoss | cut -d : -f 6)/bin/zenoss_init_pre
      set_perms
  
      echo "Zenoss initialization complete."
@@ -228,7 +228,7 @@
  fresh_install_post() {
      # run the first time initialization post-run script
 -    ${ZENHOME}/bin/zenoss_init_post
-+    $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenoss_init_post
++    $(getent passwd zenoss | cut -d : -f 6)/bin/zenoss_init_post
  }
  
  
@@ -237,7 +237,7 @@
      # run the first time initialization pre-run script
      set_perms
 -    ${ZENHOME}/bin/zenoss_upgrade_pre
-+    $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenoss_upgrade_pre
++    $(getent passwd zenoss | cut -d : -f 6)/bin/zenoss_upgrade_pre
      set_perms
  
      echo "Zenoss upgrade complete."
@@ -246,7 +246,7 @@
  
      # run the first time initialization post-run script
 -    ${ZENHOME}/bin/zenoss_upgrade_post
-+    $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenoss_upgrade_post
++    $(getent passwd zenoss | cut -d : -f 6)/bin/zenoss_upgrade_post
  
  }
  
@@ -255,7 +255,7 @@
  
  # delegate to the main zenoss script for control functions
 -su - ${RUNUSER} sh -c "${ZENHOME}/bin/zenoss $@"
-+su - ${RUNUSER} sh -c "$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenoss $@"
++su - ${RUNUSER} sh -c "$(getent passwd zenoss | cut -d : -f 6)/bin/zenoss $@"
  
  
  # run the post-script for firstboot and remove the firstboot flag
@@ -268,8 +268,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenRelations/ExportDevices.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRelations/ExportDevices.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRelations/ExportDevices.py "$CMD" $*
 diff -urNad zenoss~/bin/zendeviceload zenoss/bin/zendeviceload
 --- zenoss~/bin/zendeviceload	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zendeviceload	2007-06-15 16:14:03.000000000 +0100
@@ -279,8 +279,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenRelations/ImportDevices.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRelations/ImportDevices.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRelations/ImportDevices.py "$CMD" $*
 diff -urNad zenoss~/bin/zendisc zenoss/bin/zendisc
 --- zenoss~/bin/zendisc	2007-05-11 20:04:45.000000000 +0100
 +++ zenoss/bin/zendisc	2007-06-15 16:14:03.000000000 +0100
@@ -289,12 +289,12 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -SUDO="$ZENHOME/bin/zensocket --ping -- "
 -PRGHOME=$ZENHOME/Products/DataCollector
-+SUDO="$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zensocket --ping -- "
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/DataCollector
++SUDO="$(getent passwd zenoss | cut -d : -f 6)/bin/zensocket --ping -- "
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/DataCollector
  PRGNAME=zendisc.py
  CFGFILE=$CFGDIR/zendisc.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -307,8 +307,8 @@
  # value now to use in call to zendmd.py
 -. $ZENHOME/bin/zenfunctions
 -$PYTHON -i $ZENHOME/Products/ZenModel/zendmd.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+$PYTHON -i $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenModel/zendmd.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++$PYTHON -i $(getent passwd zenoss | cut -d : -f 6)/Products/ZenModel/zendmd.py "$CMD" $*
 diff -urNad zenoss~/bin/zendoc zenoss/bin/zendoc
 --- zenoss~/bin/zendoc	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zendoc	2007-06-15 16:14:03.000000000 +0100
@@ -321,11 +321,11 @@
 -mkdir -p $ZENHOME/zendocs/api
 -cd $ZENHOME/Products
 -$ZENHOME/bin/epydoc -o $ZENHOME/zendocs/api -n Zenoss --inheritance listed $ZENPRODUCTS
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+rm -rf $(getent passwd |grep '^zenoss' | cut -d : -f 6)/zendocs/api
-+mkdir -p $(getent passwd |grep '^zenoss' | cut -d : -f 6)/zendocs/api
-+cd $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products
-+$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/epydoc -o $(getent passwd |grep '^zenoss' | cut -d : -f 6)/zendocs/api -n Zenoss --inheritance listed $ZENPRODUCTS
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++rm -rf $(getent passwd zenoss | cut -d : -f 6)/zendocs/api
++mkdir -p $(getent passwd zenoss | cut -d : -f 6)/zendocs/api
++cd $(getent passwd zenoss | cut -d : -f 6)/Products
++$(getent passwd zenoss | cut -d : -f 6)/bin/epydoc -o $(getent passwd zenoss | cut -d : -f 6)/zendocs/api -n Zenoss --inheritance listed $ZENPRODUCTS
 diff -urNad zenoss~/bin/zendump zenoss/bin/zendump
 --- zenoss~/bin/zendump	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zendump	2007-06-15 16:14:03.000000000 +0100
@@ -335,8 +335,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenRelations/ExportRM.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRelations/ExportRM.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRelations/ExportRM.py "$CMD" $*
 diff -urNad zenoss~/bin/zeneventbuild zenoss/bin/zeneventbuild
 --- zenoss~/bin/zeneventbuild	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zeneventbuild	2007-06-15 16:14:03.000000000 +0100
@@ -345,13 +345,13 @@
  #############################################################################
  
 -if [ "$ZENHOME" = "" ]; then 
-+if [ "$(getent passwd |grep '^zenoss' | cut -d : -f 6)" = "" ]; then 
++if [ "$(getent passwd zenoss | cut -d : -f 6)" = "" ]; then 
      echo ERROR: ZENHOME envrionment variable not set.
      exit 1
  fi
  
 -EVTDB=$ZENHOME/Products/ZenEvents/db
-+EVTDB=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenEvents/db
++EVTDB=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenEvents/db
  
  if [ -d $EVTDB ]; then 
      cd $EVTDB
@@ -363,10 +363,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenWin
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenWin
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenWin
  PRGNAME=zeneventlog.py
  CFGFILE=$CFGDIR/zeneventlog.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -378,28 +378,28 @@
  #############################################################################
  
 -INSTANCE_HOME=$ZENHOME
-+INSTANCE_HOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++INSTANCE_HOME=$(getent passwd zenoss | cut -d : -f 6)
  export INSTANCE_HOME
  
 -SYBASE=$ZENHOME/sybase
-+SYBASE=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/sybase
++SYBASE=$(getent passwd zenoss | cut -d : -f 6)/sybase
  export SYBASE
  
 -ZOPEHOME=$ZENHOME
-+ZOPEHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++ZOPEHOME=$(getent passwd zenoss | cut -d : -f 6)
  if [ -d /usr/lib/zope ] ; then
     ZOPEHOME=/usr/lib/zope
  fi
  
  PYTHON=$ZOPEHOME/bin/python
 -PYTHONPATH=$ZENHOME/lib/python:$ZOPEHOME/lib/python
-+PYTHONPATH=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/lib/python:$ZOPEHOME/lib/python
++PYTHONPATH=$(getent passwd zenoss | cut -d : -f 6)/lib/python:$ZOPEHOME/lib/python
  export PYTHONPATH
  
 -VARDIR=$ZENHOME/var
 -CFGDIR=$ZENHOME/etc
-+VARDIR=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/var
-+CFGDIR=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/etc
++VARDIR=$(getent passwd zenoss | cut -d : -f 6)/var
++CFGDIR=$(getent passwd zenoss | cut -d : -f 6)/etc
  
  ZENPRODUCTS="ZenModel NcoProduct ZenUtils SiteScopeParser ZenRelations ZenStatus SnmpCollector ZenRRD DataCollector ZenWidgets ZenEvents"
  
@@ -411,10 +411,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenHub
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenHub
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenHub
  PRGNAME=zenhub.py
  CFGFILE=$CFGDIR/zenhub.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -427,8 +427,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenRelations/ImportRM.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRelations/ImportRM.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRelations/ImportRM.py "$CMD" $*
 diff -urNad zenoss~/bin/zenmail zenoss/bin/zenmail
 --- zenoss~/bin/zenmail	2007-05-11 20:04:45.000000000 +0100
 +++ zenoss/bin/zenmail	2007-06-15 16:14:03.000000000 +0100
@@ -437,12 +437,12 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -SUDO="zensocket --listen=25 -- $ZENHOME/bin/python "
 -PRGHOME=$ZENHOME/Products/ZenEvents
-+SUDO="zensocket --listen=25 -- $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/python "
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenEvents
++SUDO="zensocket --listen=25 -- $(getent passwd zenoss | cut -d : -f 6)/bin/python "
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenEvents
  PRGNAME=zenmail.py
  CFGFILE=$CFGDIR/zenmail.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -454,10 +454,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenModel
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenModel
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenModel
  PRGNAME=zenmib.py
  CFGFILE=$CFGDIR/zenmib.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -470,8 +470,8 @@
  # value now to use in call to zendmd.py
 -. $ZENHOME/bin/zenfunctions
 -$PYTHON $ZENHOME/Products/ZenModel/migrate/zenmigrate.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenModel/migrate/zenmigrate.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenModel/migrate/zenmigrate.py "$CMD" $*
 diff -urNad zenoss~/bin/zenmodeler zenoss/bin/zenmodeler
 --- zenoss~/bin/zenmodeler	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenmodeler	2007-06-15 16:14:03.000000000 +0100
@@ -480,11 +480,11 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
  
 -PRGHOME=$ZENHOME/Products/DataCollector
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/DataCollector
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/DataCollector
  PRGNAME=zenmodeler.py
  CFGFILE=$CFGDIR/zenmodeler.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -496,7 +496,7 @@
  # Attempt to set ZENHOME if it is not already set, or bogus
  # by calculating it relative to the executing command
 -if [ -z "$ZENHOME" -o ! -d "$ZENHOME" ] ; then
-+if [ -z "$(getent passwd |grep '^zenoss' | cut -d : -f 6)" -o ! -d "$(getent passwd |grep '^zenoss' | cut -d : -f 6)" ] ; then
++if [ -z "$(getent passwd zenoss | cut -d : -f 6)" -o ! -d "$(getent passwd zenoss | cut -d : -f 6)" ] ; then
      # Resolve links: $0 may be a link to zenoss's home.
      PRG="$0"
      while [ -h "$PRG" ] ; do
@@ -505,20 +505,20 @@
  
  if [ `id -u` -eq 0 ] ; then
 -   USERNAME=`ls -l $ZENHOME/var/Data.fs | awk '{ print $3 }'`
-+   USERNAME=`ls -l $(getent passwd |grep '^zenoss' | cut -d : -f 6)/var/Data.fs | awk '{ print $3 }'`
++   USERNAME=`ls -l $(getent passwd zenoss | cut -d : -f 6)/var/Data.fs | awk '{ print $3 }'`
     if [ "$USERNAME" = "root" -o -z "$USERNAME" ]  ; then 
         echo Unable to determine the right user to run zenoss
         exit 1
     fi
 -   chown -R $USERNAME $ZENHOME/var
 -   chown -R $USERNAME $ZENHOME/log
-+   chown -R $USERNAME $(getent passwd |grep '^zenoss' | cut -d : -f 6)/var
-+   chown -R $USERNAME $(getent passwd |grep '^zenoss' | cut -d : -f 6)/log
++   chown -R $USERNAME $(getent passwd zenoss | cut -d : -f 6)/var
++   chown -R $USERNAME $(getent passwd zenoss | cut -d : -f 6)/log
     exec su - $USERNAME $0 $@
  fi
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  C=
  C="$C zeoctl"
  C="$C zopectl"
@@ -527,14 +527,14 @@
  C="$C zencommand"
  C="$C zenprocess"
 -if [ -f $ZENHOME/lib/python/pywmi.py ]
-+if [ -f $(getent passwd |grep '^zenoss' | cut -d : -f 6)/lib/python/pywmi.py ]
++if [ -f $(getent passwd zenoss | cut -d : -f 6)/lib/python/pywmi.py ]
  then
      C="$C zenwin"
      C="$C zeneventlog"
      C="$C zenwinmodeler"
  fi
 -for i in $ZENHOME/Products/*/daemons/*
-+for i in $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/*/daemons/*
++for i in $(getent passwd zenoss | cut -d : -f 6)/Products/*/daemons/*
  do
     if [ -x "$i" ]
     then
@@ -543,7 +543,7 @@
      do
          echo -n "Daemon: $cmd "
 -        $ZENHOME/bin/$cmd "$FUNC"
-+        $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/$cmd "$FUNC"
++        $(getent passwd zenoss | cut -d : -f 6)/bin/$cmd "$FUNC"
      done
  }
  
@@ -555,13 +555,13 @@
  export MYSQLEVENTDB="**MYSQL_DATABASE**"
  export ZOPEPASSWORD="**ZOPE_PASSWD**"
 -export ZOPEHOME=${ZENHOME}
-+export ZOPEHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++export ZOPEHOME=$(getent passwd zenoss | cut -d : -f 6)
  
  # load the installation functions
 -. ${ZENHOME}/bin/shared-functions.sh
 -. ${ZENHOME}/bin/install-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/shared-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/install-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/shared-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/install-functions.sh
  
  
  # add localhost as a device to zenoss
@@ -573,17 +573,17 @@
  export MYSQLEVENTDB="**MYSQL_DATABASE**"
  export ZOPEPASSWORD="**ZOPE_PASSWD**"
 -export ZOPEHOME=${ZENHOME}
-+export ZOPEHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++export ZOPEHOME=$(getent passwd zenoss | cut -d : -f 6)
  
  # load the installation functions
 -. ${ZENHOME}/bin/shared-functions.sh
 -. ${ZENHOME}/bin/install-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/shared-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/install-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/shared-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/install-functions.sh
  
  # create the log directory
 -mkdir -p ${ZENHOME}/log
-+mkdir -p $(getent passwd |grep '^zenoss' | cut -d : -f 6)/log
++mkdir -p $(getent passwd zenoss | cut -d : -f 6)/log
  
  # restart external server daemons
  restart_snmpd
@@ -592,7 +592,7 @@
  # create the zeo database
  start_zeodb
 -chown -R ${OS_USERNAME} ${ZENHOME}/var
-+chown -R ${OS_USERNAME} $(getent passwd |grep '^zenoss' | cut -d : -f 6)/var
++chown -R ${OS_USERNAME} $(getent passwd zenoss | cut -d : -f 6)/var
  run_zenbuild
  stop_zeodb
 diff -urNad zenoss~/bin/zenoss_upgrade_post zenoss/bin/zenoss_upgrade_post
@@ -603,13 +603,13 @@
  export MYSQLEVENTDB="**MYSQL_DATABASE**"
  export ZOPEPASSWORD="**ZOPE_PASSWD**"
 -export ZOPEHOME=${ZENHOME}
-+export ZOPEHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++export ZOPEHOME=$(getent passwd zenoss | cut -d : -f 6)
  
  # load the installation functions
 -. ${ZENHOME}/bin/shared-functions.sh
 -. ${ZENHOME}/bin/install-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/shared-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/install-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/shared-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/install-functions.sh
  
  # do nothing...  this is left here for others to fill in later
 diff -urNad zenoss~/bin/zenoss_upgrade_pre zenoss/bin/zenoss_upgrade_pre
@@ -620,13 +620,13 @@
  export MYSQLEVENTDB="**MYSQL_DATABASE**"
  export ZOPEPASSWORD="**ZOPE_PASSWD**"
 -export ZOPEHOME=${ZENHOME}
-+export ZOPEHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++export ZOPEHOME=$(getent passwd zenoss | cut -d : -f 6)
  
  # load the installation functions
 -. ${ZENHOME}/bin/shared-functions.sh
 -. ${ZENHOME}/bin/install-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/shared-functions.sh
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/install-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/shared-functions.sh
++. $(getent passwd zenoss | cut -d : -f 6)/bin/install-functions.sh
  
  # copy the etc/*.conf.example files to etc/*.conf if etc/*.conf don't
  # already exist (we don't want to clobber people's configs)
@@ -639,8 +639,8 @@
  
 -. $ZENHOME/bin/zenfunctions
 -$PYTHON $ZENHOME/Products/ZenUtils/zenpack.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenUtils/zenpack.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenUtils/zenpack.py "$CMD" $*
 diff -urNad zenoss~/bin/zenpass zenoss/bin/zenpass
 --- zenoss~/bin/zenpass	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenpass	2007-06-15 16:14:03.000000000 +0100
@@ -649,7 +649,7 @@
  #############################################################################
  
 -cd $ZENHOME
-+cd $(getent passwd |grep '^zenoss' | cut -d : -f 6)
++cd $(getent passwd zenoss | cut -d : -f 6)
  
  echo -n 'Password for the Zenoss "admin" user: '
  stty -echo
@@ -658,7 +658,7 @@
  stty echo
  
 -test -z "$ZOPEHOME" && export ZOPEHOME=$ZENHOME
-+test -z "$ZOPEHOME" && export ZOPEHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
++test -z "$ZOPEHOME" && export ZOPEHOME=$(getent passwd zenoss | cut -d : -f 6)
  
  $ZOPEHOME/bin/zpasswd.py -u admin -p $ZOPEPASSWORD inituser
  zopectl stop
@@ -668,8 +668,8 @@
      sed -e "s/zopepassword.*/zopepassword $ZOPEPASSWORD/" < \
 -        $ZENHOME/etc/${file}.conf > /tmp/${file}.conf
 -    mv /tmp/${file}.conf $ZENHOME/etc
-+        $(getent passwd |grep '^zenoss' | cut -d : -f 6)/etc/${file}.conf > /tmp/${file}.conf
-+    mv /tmp/${file}.conf $(getent passwd |grep '^zenoss' | cut -d : -f 6)/etc
++        $(getent passwd zenoss | cut -d : -f 6)/etc/${file}.conf > /tmp/${file}.conf
++    mv /tmp/${file}.conf $(getent passwd zenoss | cut -d : -f 6)/etc
      $file restart
  done
 diff -urNad zenoss~/bin/zenperfsnmp zenoss/bin/zenperfsnmp
@@ -680,10 +680,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenRRD
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRRD
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenRRD
  PRGNAME=zenperfsnmp.py
  CFGFILE=$CFGDIR/zenperfsnmp.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -695,10 +695,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenRRD
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRRD
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenRRD
  PRGNAME=zenperfxmlrpc.py
  CFGFILE=$CFGDIR/zenperfxmlrpc.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -710,12 +710,12 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -SUDO="$ZENHOME/bin/zensocket --ping -- "
 -PRGHOME=$ZENHOME/Products/ZenStatus
-+SUDO="$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zensocket --ping -- "
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenStatus
++SUDO="$(getent passwd zenoss | cut -d : -f 6)/bin/zensocket --ping -- "
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenStatus
  PRGNAME=zenping.py
  CFGFILE=$CFGDIR/zenping.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -727,10 +727,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenRRD
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRRD
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenRRD
  PRGNAME=zenprocess.py
  CFGFILE=$CFGDIR/zenprocess.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -742,10 +742,10 @@
          exit
  else
 -    . $ZENHOME/bin/zenfunctions
-+    . $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++    . $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -    cd $ZENHOME/Products
-+    cd $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products
++    cd $(getent passwd zenoss | cut -d : -f 6)/Products
  
      for d in $ZENPRODUCTS
      do
@@ -757,10 +757,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenRRD
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRRD
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenRRD
  PRGNAME=zenrender.py
  CFGFILE=$CFGDIR/zenrender.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -773,8 +773,8 @@
  
 -. $ZENHOME/bin/zenfunctions
 -$PYTHON $ZENHOME/Products/ZenUtils/ZenRestore.py "$CMD" $*
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenUtils/ZenRestore.py "$CMD" $*
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenUtils/ZenRestore.py "$CMD" $*
 diff -urNad zenoss~/bin/zenschamadoc zenoss/bin/zenschamadoc
 --- zenoss~/bin/zenschamadoc	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenschamadoc	2007-06-15 16:14:03.000000000 +0100
@@ -784,8 +784,8 @@
  #############################################################################
 -. $ZENHOME/bin/zenfunctions 
 -$PYTHON $ZENHOME/Products/ZenRelations/schemadoc.py Products.ZenModel
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions 
-+$PYTHON $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRelations/schemadoc.py Products.ZenModel
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions 
++$PYTHON $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRelations/schemadoc.py Products.ZenModel
 diff -urNad zenoss~/bin/zenstatus zenoss/bin/zenstatus
 --- zenoss~/bin/zenstatus	2007-04-20 14:48:17.000000000 +0100
 +++ zenoss/bin/zenstatus	2007-06-15 16:14:03.000000000 +0100
@@ -794,10 +794,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenStatus
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenStatus
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenStatus
  PRGNAME=zenstatus.py
  CFGFILE=$CFGDIR/zenstatus.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -810,8 +810,8 @@
  #############################################################################
 -export INSTANCE_HOME=$ZENHOME
 -$ZENHOME/bin/python $ZENHOME/Products/ZenRRD/zenstep.py $@
-+export INSTANCE_HOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)
-+$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/python $(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenRRD/zenstep.py $@
++export INSTANCE_HOME=$(getent passwd zenoss | cut -d : -f 6)
++$(getent passwd zenoss | cut -d : -f 6)/bin/python $(getent passwd zenoss | cut -d : -f 6)/Products/ZenRRD/zenstep.py $@
 diff -urNad zenoss~/bin/zensyslog zenoss/bin/zensyslog
 --- zenoss~/bin/zensyslog	2007-05-11 20:04:45.000000000 +0100
 +++ zenoss/bin/zensyslog	2007-06-15 16:14:03.000000000 +0100
@@ -820,12 +820,12 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -SUDO="$ZENHOME/bin/zensocket --listen=514 -- "
 -PRGHOME=$ZENHOME/Products/ZenEvents
-+SUDO="$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zensocket --listen=514 -- "
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenEvents
++SUDO="$(getent passwd zenoss | cut -d : -f 6)/bin/zensocket --listen=514 -- "
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenEvents
  PRGNAME=zensyslog.py
  CFGFILE=$CFGDIR/zensyslog.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -837,12 +837,12 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -SUDO="$ZENHOME/bin/zensocket --listen=162 -- "
 -PRGHOME=$ZENHOME/Products/ZenEvents
-+SUDO="$(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zensocket --listen=162 -- "
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenEvents
++SUDO="$(getent passwd zenoss | cut -d : -f 6)/bin/zensocket --listen=162 -- "
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenEvents
  PRGNAME=zentrap.py
  CFGFILE=$CFGDIR/zentrap.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -854,10 +854,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenWin
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenWin
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenWin
  PRGNAME=zenwin.py
  CFGFILE=$CFGDIR/zenwin.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -869,10 +869,10 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
 -PRGHOME=$ZENHOME/Products/ZenWin
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenWin
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenWin
  PRGNAME=zenwinmodeler.py
  CFGFILE=$CFGDIR/zenwinmodeler.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -884,11 +884,11 @@
  #############################################################################
  
 -. $ZENHOME/bin/zenfunctions
-+. $(getent passwd |grep '^zenoss' | cut -d : -f 6)/bin/zenfunctions
++. $(getent passwd zenoss | cut -d : -f 6)/bin/zenfunctions
  
  NAME=zproprmlocal
 -PRGHOME=$ZENHOME/Products/ZenUtils
-+PRGHOME=$(getent passwd |grep '^zenoss' | cut -d : -f 6)/Products/ZenUtils
++PRGHOME=$(getent passwd zenoss | cut -d : -f 6)/Products/ZenUtils
  PRGNAME=$NAME.py
  CFGFILE=$CFGDIR/$NAME.conf
  PIDFILE=$VARDIR/$PRGNAME.pid
@@ -900,7 +900,7 @@
              parts.append('-a %s' % self.expectedIpAddress)
          cmd = ' '.join(parts)
 -        cmd = '$ZENHOME/libexec/' + \
-+        cmd = '$(getent passwd |grep '^zenoss' | cut -d : -f 6)/libexec/' + \
++        cmd = '$(getent passwd zenoss | cut -d : -f 6)/libexec/' + \
                      RRDDataSource.RRDDataSource.getCommand(self, context, cmd)
          return cmd
  
@@ -912,7 +912,7 @@
              parts.append('-f %s' % self.onRedirect) 
          cmd = ' '.join(parts)
 -        cmd = '$ZENHOME/libexec/' + \
-+        cmd = '$(getent passwd |grep '^zenoss' | cut -d : -f 6)/libexec/' + \
++        cmd = '$(getent passwd zenoss | cut -d : -f 6)/libexec/' + \
                      RRDDataSource.RRDDataSource.getCommand(self, context, cmd)
          return cmd
  

Modified: packages/zenoss/trunk/debian/zenoss.postinst
URL: http://svn.debian.org/wsvn/pkg-zenoss/packages/zenoss/trunk/debian/zenoss.postinst?rev=113&op=diff
==============================================================================
--- packages/zenoss/trunk/debian/zenoss.postinst (original)
+++ packages/zenoss/trunk/debian/zenoss.postinst Fri Jun 15 20:18:08 2007
@@ -7,7 +7,7 @@
   addgroup --system zenoss
 fi
 if ! getent passwd zenoss > /dev/null; then
-  adduser --system --ingroup zenoss --home /var/lib/zenoss zenoss
+  adduser --system --ingroup zenoss --no-create-home --home /var/lib/zenoss zenoss
 fi
 
 if ! dpkg-statoverride --list /usr/bin/zensocket > /dev/null ; then




More information about the Pkg-zenoss-commits mailing list