Don't remove pid files in $target/var/run as it is deleted afterwards anyway.
authorUlrich Dangel <uli@spamt.net>
Mon, 27 Jun 2011 13:31:32 +0000 (15:31 +0200)
committerUlrich Dangel <uli@spamt.net>
Mon, 27 Jun 2011 13:48:03 +0000 (15:48 +0200)
In some Debian suits $target/var/run is not present as /run was introduced.
If the specified directory does not exist find will return an error and the script
will fail.

etc/grml/fai/config/scripts/GRMLBASE/98-clean-chroot

index 5b7c533..c5199aa 100755 (executable)
@@ -24,10 +24,6 @@ else
   echo "Warning: localepurg not installed"
 fi
 
   echo "Warning: localepurg not installed"
 fi
 
-# find /var -name \*.pid
-echo "Removing pid-files"
-find $target/var/run -name \*.pid -exec rm {} \;
-
 echo "Removing /var/lib/apt/lists/*-stuff, dpkg-status-old and pkgcache.bin"
 rm -f $target/var/lib/apt/lists/*Packages \
       $target/var/lib/apt/lists/*Release \
 echo "Removing /var/lib/apt/lists/*-stuff, dpkg-status-old and pkgcache.bin"
 rm -f $target/var/lib/apt/lists/*Packages \
       $target/var/lib/apt/lists/*Release \