diff --git a/CHANGELOG b/CHANGELOG index bfef441..08af1c3 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -3,6 +3,7 @@ ====================== Version Description +1.0.83......Improve jail/base update, execute fetch/install commands individually. 1.0.82......Add missing system file to prevent makewhatis not found warning. 1.0.81......Update GUI pages to work with later bastille releases. 1.0.80......Add checking for FreeBSD and HardenedBSD on upgrades. diff --git a/bastille-init b/bastille-init index 5ec7577..e5febca 100755 --- a/bastille-init +++ b/bastille-init @@ -577,7 +577,9 @@ jail_update() exit 1 else env PAGER="/bin/cat" ${FREEBSD_UPDATE}/freebsd-update --not-running-from-cron -f ${FREEBSD_UPDATE}/freebsd-update.conf \ - -d ${CWDIR}/freebsd-update -b "${bastille_jailsdir}/${TARGET}/root" fetch install --currently-running "${CURRENT_VERSION}" + -d ${CWDIR}/freebsd-update -b "${bastille_jailsdir}/${TARGET}/root" fetch --currently-running "${CURRENT_VERSION}" + ${FREEBSD_UPDATE}/freebsd-update --not-running-from-cron -f ${FREEBSD_UPDATE}/freebsd-update.conf \ + -d ${CWDIR}/freebsd-update -b "${bastille_jailsdir}/${TARGET}/root" install --currently-running "${CURRENT_VERSION}" fi else echo "Container not running." @@ -596,7 +598,9 @@ jail_update() if [ -d "${bastille_releasesdir}/${TARGET}" ]; then # Update container base(affects base child containers). env PAGER="/bin/cat" ${FREEBSD_UPDATE}/freebsd-update --not-running-from-cron -f ${FREEBSD_UPDATE}/freebsd-update.conf \ - -d ${CWDIR}/freebsd-update -b "${bastille_releasesdir}/${TARGET}" fetch install --currently-running "${TARGET}" + -d ${CWDIR}/freebsd-update -b "${bastille_releasesdir}/${TARGET}" fetch --currently-running "${TARGET}" + ${FREEBSD_UPDATE}/freebsd-update --not-running-from-cron -f ${FREEBSD_UPDATE}/freebsd-update.conf \ + -d ${CWDIR}/freebsd-update -b "${bastille_releasesdir}/${TARGET}" install --currently-running "${TARGET}" else echo "${TARGET} not found. See bootstrap." exit 1 diff --git a/gui/bastille_manager_util.php b/gui/bastille_manager_util.php index 6ca330a..b870b16 100644 --- a/gui/bastille_manager_util.php +++ b/gui/bastille_manager_util.php @@ -167,8 +167,11 @@ if($_POST): if ($_POST['update_base']): $cmd = ("/usr/local/sbin/bastille-init update '{$current_release}'"); + elseif ($_POST['update_jail']): + $cmd = ("/usr/local/sbin/bastille-init update '{$item}'"); else: - $cmd = ("/usr/local/sbin/bastille-init update '{$item}' && /usr/local/sbin/bastille-init install '{$item}'"); + $input_errors[] = sprintf(gtext("Failed to update container %s."),$item); + break; endif; unset($output,$retval);mwexec2($cmd,$output,$retval); @@ -372,6 +375,7 @@ function action_change() { showElementById('jail_release_tr', 'hide'); showElementById('release_tr','hide'); showElementById('update_base_tr','hide'); + showElementById('update_jail_tr','hide'); showElementById('newname_tr', 'hide'); showElementById('newipaddr_tr', 'hide'); showElementById('clonestop_tr', 'hide'); @@ -393,6 +397,7 @@ function action_change() { showElementById('confirmname_tr','hide'); showElementById('nowstop_tr','hide'); showElementById('update_base_tr','show'); + showElementById('update_jail_tr','show'); break; case "base": showElementById('confirmname_tr','hide'); @@ -516,7 +521,7 @@ $document->render(); if ($is_thickjail): html_checkbox2('update_base',gettext('Base update confirm'),!empty($pconfig['update_base']) ? true : false,gettext('This is a thin container, therefore the base release will be updated, this affects child containers.'),'',true); else: - html_text2('update_base',gettext('Container update confirm:'),gettext('This is a thick container, therefore the update will be performed within its root, current containers are not affected.')); + html_checkbox2('update_jail',gettext('Container update confirm:'),!empty($pconfig['update_jail']) ? true : false,gettext('This is a thick container, therefore the update will be performed within its root, current containers are not affected.'),'',true); endif; html_text2('jail_release',gettext('Current base release:'),htmlspecialchars($current_release)); html_text2('auto_boot',gettext('Enable container auto-startup'),htmlspecialchars("This will cause the container to automatically start each time the system restart.")); diff --git a/version b/version index 224d004..53fe5d6 100644 --- a/version +++ b/version @@ -1 +1 @@ -1.0.82 +1.0.83