From 81a74e699a8c94bb760cd29f37bab7edd7f05994 Mon Sep 17 00:00:00 2001 From: klein panic Date: Mon, 10 Feb 2025 13:46:53 -0500 Subject: [PATCH] adding additionall mounting logic for different host systems --- chroot_manager.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/chroot_manager.sh b/chroot_manager.sh index 2ec7bde..4be82b7 100755 --- a/chroot_manager.sh +++ b/chroot_manager.sh @@ -172,10 +172,19 @@ function mount_filesystems() { log_debug "${CHROOT_DIR}/$d is already mounted." fi done + + # Mount devpts to ensure pseudo-terminal support. + if ! mountpoint -q "${CHROOT_DIR}/dev/pts"; then + log_info "Mounting devpts to ${CHROOT_DIR}/dev/pts..." + if ! sudo mount -t devpts devpts "${CHROOT_DIR}/dev/pts"; then + log_error "Error mounting devpts at ${CHROOT_DIR}/dev/pts" + exit 1 + fi + fi } function unmount_filesystems() { - local dirs=(dev proc sys tmp) + local dirs=(dev/pts dev proc sys tmp) local any_mounted=0 for d in "${dirs[@]}"; do if mountpoint -q "${CHROOT_DIR}/$d"; then