Open aj-may opened 5 years ago
You could borrow something from https://tecadmin.net/install-latest-nodejs-npm-on-ubuntu/ like this snippet:
var http = require('http');
http.createServer(function (req, res) {
res.writeHead(200, {'Content-Type': 'text/plain'});
res.end('Hello World\n');
}).listen(3000, "127.0.0.1");
console.log('Server running at http://127.0.0.1:3000/');
As @mkinney pointed out, the docs do not explain how the host based routing is configured for a container.
The README should contain more information about how the routes is configured automatically for a
docker-compose
project, as well as how to manually set a domain name using theVIRTUAL_HOST
environment variable. https://github.com/jwilder/nginx-proxy is a good reference.It would also be nice to provide a few examples.