git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@1836
94cd875c-1c1d-0410-91d2-
eb244daf1a30
vservers.
</description>
</boolean>
+
+ <boolean name="debug">
+ <description>
+When existing, the vshelper execution will be traced.
+ </description>
+ </boolean>
<boolean name="warning-disabled">
<description>
vserver.
</description>
</boolean>
+
+ <boolean name="debug">
+ <description>
+When existing, the vshelper execution will be traced for this vserver.
+ </description>
+ </boolean>
<boolean name="warning-disabled">
<description>
return 0
}
+function vshelper.isDebug [<vserver>]
+{
+ test ! -e "$CONFDIR"/.defaults/apps/vshelper/debug || return 1
+ $_VSERVER_INFO - FEATURE vshelper || return 1
+ if test -n "$2"; then
+ local appdir=$($_VSERVER_INFO "$2" APPDIR vshelper) || return 1
+ test -z "$2" -o ! -e "$appdir/debug" || return 1
+ fi
+
+ return 0
+}
+
function vshelper._getHandlerInternal
{
local _vghi_var=$1
panic $"vshelper called with missing arguments; try '--help' for more information"
vshelper.isEnabled || exit 0
+! vshelper.isDebug || set -x
set -eu