116ab5f8cf7236ca16fd71a6024cea3ef7474ee2
[openwrt/staging/yousong.git] / package / network / services / dnsmasq / files / dnsmasqsec-add-conffiles.sh
1 add_dnsmasqsec_conffiles()
2 {
3 local filelist="$1"
4
5 # do NOT include timestamp in a backup, only system upgrade
6 # dnsmasq restart ensures file timestamp is up to date
7 if [ -z $NEED_IMAGE ]; then
8 if [ $(ubus call service list '{"name":"dnsmasq"}' | jsonfilter -e '@.*.instances.instance1.running') = "true" ]; then
9 /etc/init.d/dnsmasq restart
10 sleep 1
11 echo "/etc/dnsmasq.time" >>$filelist
12 fi
13 fi
14 }
15
16 sysupgrade_init_conffiles="$sysupgrade_init_conffiles add_dnsmasqsec_conffiles"