Make directory before mounting.

This commit is contained in:
Syahrial Agni Prasetya 2021-05-28 18:12:28 +07:00
parent 286542f481
commit a6293e6098
No known key found for this signature in database
GPG Key ID: 46F88749C8C79383

View File

@ -25,6 +25,7 @@ rbind(){
if checkmount $1; then if checkmount $1; then
msg "${CHROOT}${1} already mounted." msg "${CHROOT}${1} already mounted."
else else
mkdir -p "${CHROOT}${1}"
mount -R $1 "${CHROOT}${1}" mount -R $1 "${CHROOT}${1}"
msg "${CHROOT}${1} mounted!" msg "${CHROOT}${1} mounted!"
fi fi
@ -37,6 +38,7 @@ rbind_diff() {
if checkmount $2; then if checkmount $2; then
msg "${CHROOT}${2} already mounted." msg "${CHROOT}${2} already mounted."
else else
mkdir -p "${CHROOT}${1}"
mount -R $1 "${CHROOT}${2}" mount -R $1 "${CHROOT}${2}"
msg "${CHROOT}${2} mounted!" msg "${CHROOT}${2} mounted!"
fi fi