network-config
Network configuration for NodeJS. Only used & tested on Debian
Setup
npm install network-config
Usage
List active interfaces
var network = ; network;
Update interface (static)
network.configure('eth0', {
ip: 'x.x.x.x',
netmask:'x.x.x.x',
broadcast: 'x.x.x.x',
gateway: 'x.x.x.x',
restart: true // (default) restart networking service right away
}, function(err){
})
Update interface (dhcp)
network;