diff options
author | Christian Breunig <christian@breunig.cc> | 2023-08-05 10:54:13 +0200 |
---|---|---|
committer | Christian Breunig <christian@breunig.cc> | 2023-08-05 11:01:28 +0200 |
commit | 2c8135270dafee602cd86cb19dc73366fa0a8b98 (patch) | |
tree | 49cc81b9bb1395ea7481169eb922000e861a03eb /src/etc/dhcp | |
parent | 8a15595e1ac3d9e3e15f40f8b2256768f8d71f0c (diff) | |
download | vyos-1x-2c8135270dafee602cd86cb19dc73366fa0a8b98.tar.gz vyos-1x-2c8135270dafee602cd86cb19dc73366fa0a8b98.zip |
T5428: remove hardcoded dhcp lease file path from dhclient hook
Diffstat (limited to 'src/etc/dhcp')
-rw-r--r-- | src/etc/dhcp/dhclient-exit-hooks.d/03-vyos-dhclient-hook (renamed from src/etc/dhcp/dhclient-exit-hooks.d/03-vyatta-dhclient-hook) | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/etc/dhcp/dhclient-exit-hooks.d/03-vyatta-dhclient-hook b/src/etc/dhcp/dhclient-exit-hooks.d/03-vyos-dhclient-hook index e828b433e..35721d009 100644 --- a/src/etc/dhcp/dhclient-exit-hooks.d/03-vyatta-dhclient-hook +++ b/src/etc/dhcp/dhclient-exit-hooks.d/03-vyos-dhclient-hook @@ -28,7 +28,8 @@ if [[ $reason =~ ^(REBOOT6|INIT6|EXPIRE6|RELEASE6|STOP6|INFORM6|BOUND6|REBIND6|D fi if [ "$RUN" = "yes" ]; then - LOG=/run/dhclient/dhclient_"$interface"."$proto"lease + BASE_PATH=$(python3 -c "from vyos.defaults import directories; print(directories['isc_dhclient_dir'])") + LOG=${BASE_PATH}/dhclient_"$interface"."$proto"lease echo `date` > $LOG for i in reason interface new_expiry new_dhcp_lease_time medium \ |