aboutsummaryrefslogtreecommitdiff
path: root/etc/periodic/weekly/340.noid
diff options
context:
space:
mode:
authorBrian Somers <brian@FreeBSD.org>2000-06-23 01:18:31 +0000
committerBrian Somers <brian@FreeBSD.org>2000-06-23 01:18:31 +0000
commitf3e285ba7d9ba652ea61d3aca42e6b649ae9e981 (patch)
tree1d45e43f3d06b437f0125de60d0841c0cd040b70 /etc/periodic/weekly/340.noid
parent32ee60d7b865fd8b10a81a24f1a570261af2562a (diff)
downloadsrc-f3e285ba7d9ba652ea61d3aca42e6b649ae9e981.tar.gz
src-f3e285ba7d9ba652ea61d3aca42e6b649ae9e981.zip
Introduce /etc/defaults/periodic.conf, similar in concept to rc.conf.
The only change in the default functionality should be that the output reports are slightly more verbose WRT files deleted. Not objected to by: freebsd-arch
Notes
Notes: svn path=/head/; revision=61981
Diffstat (limited to 'etc/periodic/weekly/340.noid')
-rw-r--r--etc/periodic/weekly/340.noid23
1 files changed, 15 insertions, 8 deletions
diff --git a/etc/periodic/weekly/340.noid b/etc/periodic/weekly/340.noid
index 8a94924b6703..7ad71ea07f57 100644
--- a/etc/periodic/weekly/340.noid
+++ b/etc/periodic/weekly/340.noid
@@ -1,14 +1,21 @@
#!/bin/sh -
#
# $FreeBSD$
+#
-exit 0 # do not run by default
-
-echo ""
-echo "Check for files belongs to an unknown user or unknown group:"
-
-# directories to be verified
-: ${NOIDSEARCHPATHS="/"}
+# If there is a global system configuration file, suck it in.
+#
+if [ -r /etc/defaults/periodic.conf ]
+then
+ . /etc/defaults/periodic.conf
+ source_periodic_confs
+fi
-find -H $NOIDSEARCHPATHS -fstype local \( -nogroup -or -nouser \) -print
+case "$weekly_noid_enable" in
+ [Yy][Ee][Ss])
+ echo ""
+ echo "Check for files with an unknown user or group:"
+ find -H ${weekly_noid_dirs:-/} -fstype local \
+ \( -nogroup -o -nouser \) -print | sed 's/^/ /';;
+esac