From 3f95ce086c8f49fd8393ff4aad25911188736801 Mon Sep 17 00:00:00 2001 From: Sergii Kipot Date: Tue, 29 Aug 2017 17:27:13 +0200 Subject: [PATCH] TT#20663 Fix Facter error while running in chroot Facter fails if /etc/mtab is absent: Info: Loading facts Error: Facter: setmntent failed: No such file or directory (2): mountpoints are unavailable. Info: Caching catalog for provisioning43.mgm.sipwise.com Change-Id: Ibade947caf13fdb027478050d31b5f774cf0112d --- deployment.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/deployment.sh b/deployment.sh index 560505a..2e3bcc9 100644 --- a/deployment.sh +++ b/deployment.sh @@ -2350,6 +2350,10 @@ EOF chroot ${TARGET} apt-get update chroot ${TARGET} apt-get -y install puppet-agent openssh-server lsb-release ntpdate + if [ "$DEBIAN_RELEASE" = "stretch" ]; then + chroot ${TARGET} ln -s /proc/self/mounts /etc/mtab || true + fi + cat > ${TARGET}/etc/puppetlabs/puppet/puppet.conf<< EOF # This file has been created by deployment.sh [main]