jordantrizz / mikrotik-scripts

Regular used MikroTik scripts
8 stars 5 forks source link

new param, static-custom, advice #2

Closed bzmn closed 2 years ago

bzmn commented 6 years ago

add new var - dhcpserver it mean, what is chain dns-zone and dhcp-server will be used and filter function find in dhcp-lease work only with certain dhcp-server name

static-custom now script work (add and remove) with only empty-comments dns-dhcp-records because user can add static dns record for custom but he must set comment of course.

and good advice. script can be run in lease-script (only if new records aviable). no necessary run it in schedule. for example: /ip dhcp-server add address-pool=dhcp-home authoritative=after-2sec-delay disabled=no interface=bridge-local lease-script="system script run dhcpset" lease-time=52w1d name=dhcp-server-home