From 47af9b546ea7a0f36e0f036f730b803252f0fc6e Mon Sep 17 00:00:00 2001 From: Luigi Cruz Date: Fri, 7 May 2021 18:26:44 -0300 Subject: [PATCH] Mount --- ansible/tasks/mount.yaml | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/ansible/tasks/mount.yaml b/ansible/tasks/mount.yaml index 926ce5e..c2d9e4e 100644 --- a/ansible/tasks/mount.yaml +++ b/ansible/tasks/mount.yaml @@ -3,19 +3,7 @@ connection: local shell: | ROOTFS_DIR={{ lookup('env', 'ANSIBLE_ROOTFS_DIR') }} - - if grep -q "$(realpath "${ROOTFS_DIR}"/proc)"; then - mount -t proc proc "${ROOTFS_DIR}/proc" - fi - - if grep -q "$(realpath "${ROOTFS_DIR}"/dev)"; then - mount --bind /dev "${ROOTFS_DIR}/dev" - fi - - if grep -q "$(realpath "${ROOTFS_DIR}"/dev/pts)"; then - mount --bind /dev/pts "${ROOTFS_DIR}/dev/pts" - fi - - if grep -q "$(realpath "${ROOTFS_DIR}"/sys)"; then - mount --bind /sys "${ROOTFS_DIR}/sys" - fi \ No newline at end of file + mount -t proc proc "${ROOTFS_DIR}/proc" + mount --bind /dev "${ROOTFS_DIR}/dev" + mount --bind /dev/pts "${ROOTFS_DIR}/dev/pts" + mount --bind /sys "${ROOTFS_DIR}/sys" \ No newline at end of file