summaryrefslogtreecommitdiffstats
path: root/net/wifidog/files/wifidog.init
blob: 6ebf64fbcb1c219baccdc7b1bee8c7ce4ff7a9ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh /etc/rc.common
# Copyright (C) 2006 OpenWrt.org
START=65

USE_PROCD=1

EXTRA_COMMANDS="status"
EXTRA_HELP="        status Print the status of the service"

start_service() {
    procd_open_instance
    # -s: log to syslog
    # -f: run in foreground
    procd_set_param command /usr/bin/wifidog -s -f
    procd_set_param respawn # respawn automatically if something died
    procd_set_param file /etc/wifidog.conf
    procd_close_instance
}

status() {
    /usr/bin/wdctl status
}