#!/bin/sh

post_process_ce() {
    local rootfs
    rootfs="$1"

    # switch the guest into base (orel) mode
    install_packages "${rootfs}" astra-safepolicy
    chroot "${rootfs}" astra-modeswitch set 0
}

scdir=$(dirname "$0")
. "$scdir"/astra-util.sh

if dpkg -l astra-safepolicy >/dev/null 2>&1 && test -f /usr/sbin/astra-modeswitch ; then
    post_process_ce "${rootfs}"
fi
