loopback-ssl
Advanced tools
Comparing version 0.0.1 to 0.0.2
25
index.js
'use strict'; | ||
var https = require('https'); | ||
var fs = require('fs'); | ||
/** | ||
* | ||
* @param app | ||
*/ | ||
var startServer = function(app) { | ||
if (app.get('httpMode')) { | ||
return startHttp(app); | ||
} else { | ||
return startHttps(app); | ||
} | ||
}; | ||
var startHttp = function(app) { | ||
return app.listen(function() { | ||
app.emit('started'); | ||
var baseUrl = app.get('url').replace(/\/$/, ''); | ||
console.log('Web server listening at: %s', baseUrl); | ||
if (app.get('loopback-component-explorer')) { | ||
var explorerPath = app.get('loopback-component-explorer').mountPath; | ||
console.log('Browse your REST API at %s%s', baseUrl, explorerPath); | ||
} | ||
}); | ||
}; | ||
exports.startServer = startServer; | ||
module.exports.startServer = startServer; |
{ | ||
"name": "loopback-ssl", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"description": "Node module to enable SSL or Mutual SSL in any loopback application", | ||
@@ -23,3 +23,15 @@ "main": "index.js", | ||
}, | ||
"homepage": "https://github.com/yantrashala/loopback-ssl#readme" | ||
} | ||
"homepage": "https://github.com/yantrashala/loopback-ssl#readme", | ||
"devDependencies": { | ||
"eslint-config-loopback": "4.0.0", | ||
"gulp": "3.9.1", | ||
"gulp-eslint": "3.0.1", | ||
"gulp-if": "2.0.1", | ||
"gulp-istanbul": "1.0.0", | ||
"gulp-mocha": "2.2.0", | ||
"gulp-nsp": "2.4.2", | ||
"gulp-shrinkwrap": "2.0.1", | ||
"nsp": "2.6.1", | ||
"shrinkwrap": "0.4.0" | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
139
1
22
7380
10
11