var interfaces = os.networkInterfaces();
for(var i in interfaces){
var _item = interfaces[i];
for(var j in _item){
if(_item[j]["internal"] == false && _item[j]["family"] == "IPv4"){
console.log("server ip = ",_item[j]["address"]);
break;
}
}
}
}