dhcpcd revision 1.8
1#!/bin/sh
2
3# $NetBSD: dhcpcd,v 1.8 2020/04/02 12:58:49 roy Exp $
4
5# PROVIDE: dhcpcd
6# REQUIRE: network mountcritlocal
7# BEFORE:  NETWORKING
8# KEYWORD: chrootdir
9
10$_rc_subr_loaded . /etc/rc.subr
11
12name=dhcpcd
13rcvar=$name
14command=/sbin/$name
15extra_commands="reload"
16
17load_rc_config $name
18
19# Work out what pidfile dhcpcd will use based on flags
20if [ -n "$flags" ]; then
21	myflags=$flags
22else
23	eval myflags=\$${name}_flags
24fi
25pidfile=$(eval $command -P $myflags 2>/dev/null)
26: ${pidfile:=/var/run/$name.pid}
27unset myflags
28
29run_rc_command "$1"
30