d2946278f5
git-svn-id: svn://svn.openwrt.org/openwrt/packages@8777 3c298f89-4303-0410-b956-a3cf2f4a3e73
26 lines
502 B
Bash
26 lines
502 B
Bash
#!/bin/sh /etc/rc.common
|
|
# Copyright (C) 2006 OpenWrt.org
|
|
START=50
|
|
|
|
start_service () {
|
|
local section="$1"
|
|
config_get service "$section" service
|
|
config_get username "$section" username
|
|
config_get password "$section" password
|
|
config_get host "$section" host
|
|
config_get update "$section" update
|
|
|
|
[ "$update" = 1 ] && {
|
|
/usr/bin/updatedd -Y $service -- $username:$password $host
|
|
}
|
|
}
|
|
|
|
start() {
|
|
config_load "updatedd"
|
|
config_foreach start_service updatedd
|
|
}
|
|
|
|
stop() {
|
|
killall updatedd
|
|
}
|