summaryrefslogtreecommitdiff
path: root/cfengine/script.update_sambashares.sh
blob: 4ace9aa0c9541909a9221388c8fc4690f4894bff (plain)
  1. #!/bin/sh
  2. # Fail on error - to leave cf_tmpfile for investigation
  3. set -e
  4. m4 -DFQDN=$(hostname -f) /etc/local-COMMON/samba/smb-shares.conf.m4 >> /etc/samba/smb-shares.conf
  5. cf_tmpfile=`tempfile -p cf`
  6. m4 -DFQDN=$(hostname -f) /etc/local-COMMON/cfengine/cf.services.file.tmp.m4 > $cf_tmpfile
  7. cfengine -q -f $cf_tmpfile
  8. rm -f $cf_tmpfile