added contrib files
This commit is contained in:
Executable
+12
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
API_KEY=
|
||||
URL=https://phantom1.lan:53443
|
||||
|
||||
awk '{print $2,$6,$8}' dhcp.static | tr -d \; | grep '192.168.2\.' | while read -r domain mac ipaddr; do
|
||||
echo -n "$domain|$mac|$ipaddr"
|
||||
curl --insecure --silent --header "Authorization: Bearer $API_KEY" "$URL/api/dhcp/scopes/addReservedLease?name=dhcp2&hardwareAddress=$mac&ipAddress=$ipaddr&hostName=$domain"
|
||||
echo
|
||||
done
|
||||
|
||||
|
||||
Reference in New Issue
Block a user