move requiresOAuthProxy to nginx
we have 3 levels
* routes, cron, apptask
* everything else where everyone calls everyone :-)
* the db layer
This commit is contained in:
+2
-3
@@ -101,12 +101,11 @@ function configureNginx(app, callback) {
|
||||
assert.strictEqual(typeof callback, 'function');
|
||||
|
||||
var vhost = config.appFqdn(app.location);
|
||||
var oauthProxy = apps.requiresOAuthProxy(app);
|
||||
|
||||
certificates.ensureCertificate(vhost, function (error, certFilePath, keyFilePath) {
|
||||
if (error) return callback(error);
|
||||
|
||||
nginx.configureApp(app, oauthProxy, certFilePath, keyFilePath, callback);
|
||||
nginx.configureApp(app, certFilePath, keyFilePath, callback);
|
||||
});
|
||||
}
|
||||
|
||||
@@ -163,7 +162,7 @@ function allocateOAuthProxyCredentials(app, callback) {
|
||||
assert.strictEqual(typeof app, 'object');
|
||||
assert.strictEqual(typeof callback, 'function');
|
||||
|
||||
if (!apps.requiresOAuthProxy(app)) return callback(null);
|
||||
if (!nginx.requiresOAuthProxy(app)) return callback(null);
|
||||
|
||||
var id = 'cid-' + uuid.v4();
|
||||
var clientSecret = hat(256);
|
||||
|
||||
Reference in New Issue
Block a user