HEX
Server: Apache/2.2.34 (Unix) mod_fastcgi/mod_fastcgi-SNAP-0910052141
System: Linux Kou-Etsu-Dou 4.4.59+ #25556 SMP PREEMPT Thu Mar 4 18:03:46 CST 2021 x86_64
User: hosam (1026)
PHP: 7.2.29
Disabled: NONE
Upload Files
File: //proc/thread-self/root/etc.defaults/init/smallupdate.conf
description	"DDSM smallupdate restore from share"

start on stopped dsmupdate

task

console log

script
	smallUpdateDir="/smallupd@te"
	smallUpdater="${smallUpdateDir}/smallupd@ter"
	configUpdater="${smallUpdateDir}/configupdate"

	if [ ! -d "$smallUpdateDir" ]; then
		exit 0
	fi

	if [ -x "${configUpdater}" ]; then
		/bin/echo "Perform config update for smallupdate" || true
		if ! ${configUpdater} -c all -p /etc.defaults/VERSION; then
			/bin/echo "Failed to update config for smallupdate" || true
			/bin/rm -rf "${smallUpdateDir}" || true
			exit 0
		fi
	fi

	if [ -x "$smallUpdater" ]; then
		/bin/date -u
		$smallUpdater -t || true
	fi
	/bin/rm -rf "${smallUpdateDir}" || true
	/bin/touch /var/.SmallupdateBootup || true
end script
# vim:ft=upstart