From: Frank Brehm Date: Fri, 7 Jan 2022 11:09:23 +0000 (+0100) Subject: Adding Gitlab job log sections X-Git-Tag: 2.3.3^2~3^2~1 X-Git-Url: https://git.uhu-banane.org/?a=commitdiff_plain;h=04d63ea2b8e1a0e092940d15bcb12746ae760522;p=pixelpark%2Fcreate-vmware-tpl.git Adding Gitlab job log sections --- diff --git a/lib/cr_vmware_tpl/cobbler.py b/lib/cr_vmware_tpl/cobbler.py index ec42779..a3b8601 100644 --- a/lib/cr_vmware_tpl/cobbler.py +++ b/lib/cr_vmware_tpl/cobbler.py @@ -794,7 +794,7 @@ class Cobbler(BaseHandler): """Removing the given system.""" LOG.info(_("Removing system {!r} ...").format(name)) - print_section_start('remove_system', "Creating new system ...", collapsed=True) + print_section_start('remove_system', "Removing system ...", collapsed=True) args = ['system', 'remove'] args.append('--name') @@ -813,8 +813,8 @@ class Cobbler(BaseHandler): print_section_end('remove_system') raise ExpectedCobblerError(msg) - print_section_end('remove_system') self.sync() + print_section_end('remove_system') # ------------------------------------------------------------------------- def sync(self): diff --git a/snippets/tpl.010.authkeys.sh b/snippets/tpl.010.authkeys.sh index 3e7ef50..387ce5f 100644 --- a/snippets/tpl.010.authkeys.sh +++ b/snippets/tpl.010.authkeys.sh @@ -4,6 +4,7 @@ #----------------------------------------------------------- create_authkeys() { + echo -e "\e[0Ksection_start:$( date +%s ):ks_create_authkeys[collapsed=true]\r\e[0KCreating authorized_keys of root ..." echo echo "${HASH_LINE}" echo "Calling create_authkeys() ..." @@ -24,6 +25,7 @@ create_authkeys() { cat "${tmp_file}" >> /root/.ssh/authorized_keys fi rm -v "${tmp_file}" + echo -e "\e[0Ksection_end:$( date +%s ):ks_create_authkeys\r\e[0K" } create_authkeys