duiadns: use touch to update timefile in runit service

When on an NFS volume, the shell redirection `: > $TIMEFILE` seems to
short-circuit the empty write when the file is already empty, so the
mtime is never updated. Using `touch` yields expected behavior.
This commit is contained in:
Andrew J. Hesford 2021-01-22 10:45:03 -05:00
parent c1b44d634c
commit ebb535ed9f
2 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ if command -v snooze >/dev/null 2>&1; then
exec chpst -u _duiadns:_duiadns \
snooze ${PERIOD} -t "${TIMEFILE}" \
sh -c "/usr/bin/duiadns '${CONFIG}'; : > '${TIMEFILE}'"
sh -c "/usr/bin/duiadns '${CONFIG}'; touch '${TIMEFILE}'"
else
# Fall back to dumb sleep if snooze is not available
# PERIOD is just the number of seconds to sleep in this context

View File

@ -1,7 +1,7 @@
# Template file for 'duiadns'
pkgname=duiadns
version=1.1
revision=2
revision=3
build_style=python3-module
hostmakedepends="python3-setuptools"
depends="python3-netifaces python3-netaddr python3-requests"