mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-26 15:32:30 +00:00
refactor: Simplify enabling debug
Simplify the logic to enable debug and also enable debug as early as possible. Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
This commit is contained in:
parent
2b2b68d6fa
commit
f3e89d38a9
@ -6,13 +6,11 @@
|
||||
|
||||
set -e
|
||||
|
||||
[ -n "$DEBUG" ] && set -x
|
||||
|
||||
script_name="${0##*/}"
|
||||
script_dir="$(dirname $(readlink -f $0))"
|
||||
|
||||
if [ -n "$DEBUG" ] ; then
|
||||
set -x
|
||||
fi
|
||||
|
||||
SCRIPT_NAME="${0##*/}"
|
||||
IMAGE="${IMAGE:-kata-containers.img}"
|
||||
AGENT_BIN=${AGENT_BIN:-kata-agent}
|
||||
|
@ -6,13 +6,11 @@
|
||||
|
||||
set -e
|
||||
|
||||
[ -n "$DEBUG" ] && set -x
|
||||
|
||||
script_name="${0##*/}"
|
||||
script_dir="$(dirname $(readlink -f $0))"
|
||||
|
||||
if [ -n "$DEBUG" ] ; then
|
||||
set -x
|
||||
fi
|
||||
|
||||
SCRIPT_NAME="${0##*/}"
|
||||
INITRD_IMAGE="${INITRD_IMAGE:-kata-containers-initrd.img}"
|
||||
AGENT_BIN=${AGENT_BIN:-kata-agent}
|
||||
|
@ -6,6 +6,8 @@
|
||||
|
||||
set -e
|
||||
|
||||
[ -n "$DEBUG" ] && set -x
|
||||
|
||||
script_name="${0##*/}"
|
||||
script_dir="$(dirname $(readlink -f $0))"
|
||||
AGENT_VERSION=${AGENT_VERSION:-master}
|
||||
@ -26,10 +28,6 @@ typeset -r CONFIG_SH="config.sh"
|
||||
# Name of the extra file that could implement build_rootfs
|
||||
typeset -r LIB_SH="rootfs_lib.sh"
|
||||
|
||||
if [ -n "$DEBUG" ] ; then
|
||||
set -x
|
||||
fi
|
||||
|
||||
#$1: Error code if want to exit differnt to 0
|
||||
usage(){
|
||||
error="${1:-0}"
|
||||
|
Loading…
Reference in New Issue
Block a user