1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-11-24 17:28:08 +00:00
gns3-server/gns3server/compute/docker/resources/bin/udhcpc
2023-01-06 20:09:17 +08:00

16 lines
323 B
Plaintext
Executable File

#!/gns3/bin/busybox sh
SCRIPT="/gns3/etc/udhcpc/default.script"
if [ "$(cat "/proc/$PPID/comm" 2>/dev/null)" = ifup ]; then
# remove "-n" argument
for arg do
shift
[ "$arg" = "-n" ] || set -- "$@" "$arg"
done
# add default parameters
set -- -t 3 -T 2 -A 1 -b "$@"
fi
exec /tmp/gns3/bin/udhcpc -s "$SCRIPT" "$@"