#! /bin/bash set -e export DEBIAN_FRONTEND="noninteractive" export ORIGINAL_WORKINGDIR=$(pwd) for hook in /etc/chroot_scripts/hooks/* do $hook cd $ORIGINAL_WORKINGDIR done