diff --git a/lxd-stophook-wrapper/lxd b/lxd-stophook-wrapper/lxd new file mode 100755 index 00000000..eb30b223 --- /dev/null +++ b/lxd-stophook-wrapper/lxd @@ -0,0 +1,8 @@ +#!/bin/sh +# Use exec so that this script process is replaced. +# This avoids polluting the process tree with this wrapper script. +if [ "$1" = "callhook" ]; then + exec /snap/lxd/current/bin/lxd-user "$@" +else + exec lxd "$@" +fi