A Node JS server architecture to connect to high performance computers via SSH and manage experiments.
- Server: express
- Templating engine: swig
- Generate SSH key pairs: ssh-keygen
- Connect via SSH: ssh2
var workflow = require( 'hpwc-workflow' );
// HTTP Server
workflow({ port: 8080 });
// HTTPS Server
workflow({
port: 443,
production: true,
keyfile: 'config/https-key.pem',
certfile: 'config/https-cert.pem'
});
###init( options )
Where options
can contain following optional arguments:
- loglevel: one of
['fatal'|'error'|'warn'|'info'|'debug'|'trace']
- port: The port on which to run the server
- production: Set this property and the system will be run in production mode. Sets the process.env.NODE_ENV accordingly, plus disables caching on the server side if in production mode. Default is production=false which turns off caching of web pages through the rendering engine
- keyfile: The path to the key file in order to run a HTTPS server
- certfile: The path to the certificate file in order to run a HTTPS server