diff options
Diffstat (limited to 'examples/source/fifodir-cleanup')
-rw-r--r-- | examples/source/fifodir-cleanup/dependencies | 1 | ||||
-rwxr-xr-x | examples/source/fifodir-cleanup/run | 15 | ||||
-rw-r--r-- | examples/source/fifodir-cleanup/type | 1 |
3 files changed, 17 insertions, 0 deletions
diff --git a/examples/source/fifodir-cleanup/dependencies b/examples/source/fifodir-cleanup/dependencies new file mode 100644 index 0000000..4daddb7 --- /dev/null +++ b/examples/source/fifodir-cleanup/dependencies @@ -0,0 +1 @@ +00 diff --git a/examples/source/fifodir-cleanup/run b/examples/source/fifodir-cleanup/run new file mode 100755 index 0000000..5a34a9b --- /dev/null +++ b/examples/source/fifodir-cleanup/run @@ -0,0 +1,15 @@ +#!/command/execlineb -P +fdmove -c 2 1 +if +{ + forbacktickx -ep -0 i { s6-ls -0 /service } + import -u i + foreground + { + if { s6-test -d /service/${i}/log } + s6-cleanfifodir /service/${i}/log/event + } + s6-cleanfifodir /service/${i}/event +} +s6-setuidgid nobody +s6-sleep 86400 diff --git a/examples/source/fifodir-cleanup/type b/examples/source/fifodir-cleanup/type new file mode 100644 index 0000000..5883cff --- /dev/null +++ b/examples/source/fifodir-cleanup/type @@ -0,0 +1 @@ +longrun |