How can I get the server name for where node.js is running? -


i want add line point different database depending on server running node.js on (localhost vs test.com, etc). how server name in node.js? is, server side equivalent location.host?

var os = require('os'); os.hostname(); 

link


Comments

Popular posts from this blog

python - mat is not a numerical tuple : openCV error -

c# - MSAA finds controls UI Automation doesn't -

wordpress - .htaccess: RewriteRule: bad flag delimiters -