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
changes/54/15154/3
Sergii Kipot 8 years ago
parent 92b0a2d89c
commit 3f95ce086c

@ -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]

Loading…
Cancel
Save