From 467c32600cc575fcb67c5f01ad32e02141220ceb Mon Sep 17 00:00:00 2001 From: "Leon M. George" Date: Tue, 23 Mar 2021 11:02:36 +0100 Subject: netifd: read udhcpc user scripts from directory Placeholder DHCP user scripts were added recently. These files make package-based installations of such scripts more difficult. Pull user callbacks from directories instead to allow packages and users to install co-existing scripts more easily. References: 130118f7a netifd: add a udhcpc.user placeholder script Signed-off-by: Leon M. George Signed-off-by: Hans Dedecker [PKG_RELEASE increase] --- package/network/config/netifd/files/lib/netifd/dhcp.script | 3 +++ 1 file changed, 3 insertions(+) (limited to 'package/network/config/netifd/files') diff --git a/package/network/config/netifd/files/lib/netifd/dhcp.script b/package/network/config/netifd/files/lib/netifd/dhcp.script index 6585b641d6..e46005d84c 100755 --- a/package/network/config/netifd/files/lib/netifd/dhcp.script +++ b/package/network/config/netifd/files/lib/netifd/dhcp.script @@ -112,5 +112,8 @@ esac # user rules [ -f /etc/udhcpc.user ] && . /etc/udhcpc.user "$@" +for f in /etc/udhcpc.user.d/*; do + [ -f "$f" ] && (. "$f" "$@") +done exit 0 -- cgit v1.2.3