Class NetworkInterfaceAliases
java.lang.Object
org.eblocker.server.common.network.unix.NetworkInterfaceAliases
This class can be used to dynamically add or remove interface aliases.
-
Constructor Summary
ConstructorsConstructorDescriptionNetworkInterfaceAliases(String interfaceName, int aliasMin, int aliasMax, String addAliasScript, String removeAliasScript, ScriptRunner scriptRunner) -
Method Summary
Modifier and TypeMethodDescriptionAdd an ip with netmask the primary interface.voidRemoves an assigned alias from the primary interface
-
Constructor Details
-
NetworkInterfaceAliases
@Inject public NetworkInterfaceAliases(String interfaceName, int aliasMin, int aliasMax, String addAliasScript, String removeAliasScript, ScriptRunner scriptRunner)
-
-
Method Details
-
add
Add an ip with netmask the primary interface.- Parameters:
ip- ip to assignnetmask- netmask to assin- Returns:
- assigned alias
-
remove
Removes an assigned alias from the primary interface- Parameters:
alias- to remove
-
getAliasedIps
-