ctdb-scripts: New functions ip_block() and ip_unblock()
authorMartin Schwenke <martin@meltin.net>
Fri, 13 May 2016 09:43:05 +0000 (19:43 +1000)
committerMartin Schwenke <martins@samba.org>
Thu, 26 May 2016 06:04:29 +0000 (08:04 +0200)
commitb4878cfc4deba1da5f205bf8f7c5bee05ee380ba
treed4bf70353bdba9023e0ca762293985aab60df0f6
parent1fd7c28d5fb575e75b5085e8589aef2525c8e784
ctdb-scripts: New functions ip_block() and ip_unblock()

Block and unblock IP addresses using these new functions.  This makes
the code more readable.

The case statement in each function is very cheap, so there is no need
to prematurely optimise and pass the family.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/config/events.d/10.interface