From 7f5329cb6df68c5a6ad488c3c6c83f9bab972487 Mon Sep 17 00:00:00 2001 From: Stephen Benjamin Date: Thu, 29 Aug 2019 10:37:00 -0400 Subject: [PATCH] Set GOTRACEBACK=crash by default Ensure if a go program crashes we get a coredump (especially to nail down that's causing https://github.com/openshift/oc/issues/58). To get the dump, use coredumpctl: coredumpctl -o oc.coredump dump /usr/local/bin/oc --- common.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/common.sh b/common.sh index db4eaf2f4..9e4568615 100644 --- a/common.sh +++ b/common.sh @@ -2,6 +2,14 @@ eval "$(go env)" +# Ensure if a go program crashes we get a coredump (especially to nail +# down that's causing https://github.com/openshift/oc/issues/58). +# +# To get the dump, use coredumpctl: +# coredumpctl -o oc.coredump dump /usr/local/bin/oc +# +export GOTRACEBACK=crash + SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" USER=`whoami`