node-http-server
Version:
A very simple and fast http server for node, bash, and spawnable from C, Python etc. It is lightweight and great for embedded solutions as well as everyday development or public facing apps.
21 lines (18 loc) • 545 B
JavaScript
//import the `node-http-server` module
//` const server=require(‘node-http-server’); `
const server=require('../../server/Server.js');
//start the server
server.deploy(
{
port:8000,
root:__dirname+'/appRoot/',
log:'/tmp/server-test-myApp-8000-request.log',
https:{
privateKey:`${__dirname}/../../local-certs/private/server.key`,
certificate:`${__dirname}/../../local-certs/server.pub`,
port:4433
}
}
);
//checkout the server instance
console.log(server);