Skip to content

Instantly share code, notes, and snippets.

@shivasurya
Created August 13, 2014 14:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shivasurya/f54ef7783a626cb79e05 to your computer and use it in GitHub Desktop.
Save shivasurya/f54ef7783a626cb79e05 to your computer and use it in GitHub Desktop.
// server.js
// set up ======================================================================
// get all the tools we need
var path = require('path');
var express = require('express');
var app = express();
var port = process.env.OPENSHIFT_NODEJS_PORT || 8080
, ip = process.env.OPENSHIFT_NODEJS_IP || "127.0.0.1";
var mongoose = require('mongoose');
var passport = require('passport');
// launch ======================================================================
app.listen(port);
console.log('The magic happens on port ' + port);
//this is sample server.js file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment