fix copy/paste error, use proper prefix and suffix

Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
This commit is contained in:
Steven Armstrong 2012-01-06 10:50:01 +01:00
parent 4e4a1598b2
commit b67d785a24
1 changed files with 2 additions and 3 deletions

View File

@ -21,12 +21,11 @@
export="$(cat "$__object/parameter/export" 2>/dev/null || echo "/$__object_id")"
name="$(echo "${export#/}" | sed 's;/;-;g')"
prefix="#cdist:__cron/$export"
suffix="#/cdist:__cron/$export"
if [ -f "/etc/exports.d/$name" ]; then
cat "/etc/exports.d/$name"
else
prefix="#cdist:__nfs_export${export}"
suffix="#/cdist:__nfs_export${export}"
awk -v prefix="$prefix" -v suffix="$suffix" '{
if (index($0,prefix)) {
triggered=1