Permalink
Browse files

add SSL support

  • Loading branch information...
lpatters committed Jun 8, 2011
1 parent 9b21d84 commit 403ecb6b93917fd65437e7c3a4f51f5fea08eb0d
Showing with 5 additions and 1 deletion.
  1. +5 −1 lib/jsgi-node.js
View
@@ -226,6 +226,10 @@ exports.start = function( app, options ) {
var port = options.port || 8080;
- require( "http" ).createServer( app ).listen( port );
+ if (options.ssl) {
+ require( "https" ).createServer(options.ssl, app).listen(port);
+ } else {
+ require( "http" ).createServer( app ).listen( port );
+ }
sys.puts( "Server running on port " + port );
};

0 comments on commit 403ecb6

Please sign in to comment.