2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-22 03:32:04 +00:00

Get xCAT MASTER from dhcpclient lease file for configinterface postscripts (#4834)

* Get MASTER from dhcp identifier for configinterface postscripts

* modify MASTER line
This commit is contained in:
cxhong 2018-02-22 21:42:42 -05:00 committed by yangsong
parent 2ca56404d9
commit a81b6e2728

View File

@ -9,6 +9,7 @@ fi
xcat_intf="/etc/network/interfaces.d/xCAT.intf"
MASTER=$(cat /var/lib/dhcp/dhclient.eth0.leases|sed -n 's/.*cumulus-provision-url.*http:\/\+\([^\/]\+\)\/.*/\1/p'|tail -1)
if [ -z "$MASTER" ]; then
echo "xCAT Master unset! Cannot download interface description"
exit 2