summaryrefslogtreecommitdiffstats
path: root/hooks
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2018-02-20 09:06:38 +0000
committerRoy Marples <roy@marples.name>2018-02-20 09:06:38 +0000
commitd531f8b063c23d6fa62a6f0c5b5e69e849da4600 (patch)
treed6ad830dc3e42fa5f1f270ed5e845056d02b8c02 /hooks
parentd6be59934ab8e350a6e6d897ccf8a9cd46d74847 (diff)
downloaddhcpcd-d531f8b063c23d6fa62a6f0c5b5e69e849da4600.tar.xz
hooks: document that hooks are not run within their own process
Diffstat (limited to 'hooks')
-rw-r--r--hooks/dhcpcd-run-hooks.8.in15
1 files changed, 14 insertions, 1 deletions
diff --git a/hooks/dhcpcd-run-hooks.8.in b/hooks/dhcpcd-run-hooks.8.in
index ada5c6b3..1387b545 100644
--- a/hooks/dhcpcd-run-hooks.8.in
+++ b/hooks/dhcpcd-run-hooks.8.in
@@ -22,7 +22,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd November 3, 2017
+.Dd Febuary 20, 2018
.Dt DHCPCD-RUN-HOOKS 8
.Os
.Sh NAME
@@ -47,6 +47,19 @@ ntp or ypbind.
A test hook is also supplied that simply echos the dhcp variables to the
console from DISCOVER message.
.Pp
+The hooks scripts are loaded into the current shell rather than executed
+in their own process.
+This allows each hook script, such as
+.Pa @SYSCONFDIR@/dhcpcd.enter-hook
+to customise environment variables or provide alternative functions to hooks
+further down the chain.
+As such, using the shell builtins
+.Ic exit ,
+.Ic exec
+or similar will cause
+.Nm
+to exit at that point.
+.Pp
Each time
.Nm
is invoked,