diff options
| author | yo mama <pepper@scannerjammer.com> | 2014-12-05 19:46:45 -0800 |
|---|---|---|
| committer | yo mama <pepper@scannerjammer.com> | 2014-12-05 19:46:45 -0800 |
| commit | 4d73eb92cbc135850e20b2390698105ff8edf3cd (patch) | |
| tree | 5bd94a3e6ae4435b54dea08e19396d65267054e0 /bin/app.js | |
| parent | e387304922f6379cebebaaa511c608855d8acba1 (diff) | |
waiting until everyauth is updatedeveryauth
Diffstat (limited to 'bin/app.js')
| -rwxr-xr-x | bin/app.js | 31 |
1 files changed, 26 insertions, 5 deletions
@@ -7,20 +7,41 @@ var express = require('express'), bodyParser = require('body-parser'),
cookieSession = require('cookie-session');
var config = require('../config/main');
-
+var everyauth = require('everyauth');
+
var app = express();
app.use(morgan('combined'));
-app.use(bodyParser.json()); // for parsing application/json
app.use(multer({inMemory: true}));
-app.use(bodyParser.urlencoded({ extended: true })); // for parsing application/x-www-form-urlencoded
app.use(expressValidator());
-app.use(cookieParser());
-app.use(cookieSession({secret: 'app_1'}));
+app.use(bodyParser.json()); // for parsing application/json
+app.use(bodyParser.urlencoded({ extended: true })); // for parsing application/x-www-form-urlencoded
+app.use(cookieParser('some secret'));
+app.use(express.session());
+app.use(everyauth.middleware(app));
+//app.use(cookieSession({secret: 'app_1'}));
app.use(express.static('../public'));
app.use(express.static('../public/vendor'));
//app.use(express.favicon(__dirname + '/public/images/shortcut-icon.png'));
//app.use(messages());
+//Important - Some OAuth Providers do not allow callbacks to localhost,
+// so you will need to create a localhost alias called local.host. Make
+// sure you set up your /etc/hosts so that 127.0.0.1 is also associated
+//with 'local.host'. So inside your /etc/hosts file,
+// one of the lines will look like:
+//
+//127.0.0.1 localhost local.host
+//ABORT ABORT
+//this project needs to be updated to not use connect
+//CONTINUE LATER...for the time being use passport
+//
+//
+//
+//
+
+//
+
+
app.set('view engine', 'ejs');
app.set('views', 'views');
|
