From: Frank Brehm Date: Tue, 23 Jun 2020 08:42:04 +0000 (+0200) Subject: Display of Postinstall Log X-Git-Tag: 2.1.2^2~9^2~31^2~6 X-Git-Url: https://git.uhu-banane.org/?a=commitdiff_plain;h=ee633c16ad74fef829ee0a1a438aec85df7653f3;p=pixelpark%2Fcreate-vmware-tpl.git Display of Postinstall Log --- diff --git a/kickstart/template-centos8.ks b/kickstart/template-centos8.ks index d3784d7..f1adae4 100644 --- a/kickstart/template-centos8.ks +++ b/kickstart/template-centos8.ks @@ -117,7 +117,7 @@ exec < /dev/console &> >(tee -a "$POST_LOG") ### debug -set -x +# set -x echo "cobbler profile = $profile_name" echo diff --git a/lib/cr_vmware_tpl/handler.py b/lib/cr_vmware_tpl/handler.py index 30bf869..e87e097 100644 --- a/lib/cr_vmware_tpl/handler.py +++ b/lib/cr_vmware_tpl/handler.py @@ -42,7 +42,7 @@ from .cobbler import CobblerError, Cobbler from .xlate import XLATOR -__version__ = '1.7.3' +__version__ = '1.7.4' LOG = logging.getLogger(__name__) TZ = pytz.timezone('Europe/Berlin') @@ -310,8 +310,7 @@ class CrTplHandler(BaseHandler): return 10 else: self.poweroff_vm() - - self.cobbler.remove_system(tpl_sysname) + self.cobbler.remove_system(tpl_sysname) return 0 @@ -680,6 +679,24 @@ class CrTplHandler(BaseHandler): fi done + if [ -f /var/log/anaconda/post-install.log ] ; then + echo + echo "Post install log:" + echo + echo "-----------------------------------------------------------" + cat /var/log/anaconda/post-install.log + echo "-----------------------------------------------------------" + echo + else + echo + echo "###########################################################" + echo + echo "Post install log not found!" + echo + echo "###########################################################" + echo + fi + """) try: