Parse Server 101
David Olesch, 2016 1
Node.js is easy.
Why not code the server yourself?
David Olesch, 2016 2
Features
David Olesch, 2016 3
How much does it cost to host Parse
Server?
David Olesch, 2016 4
How long does it take to setup on
the back end and front end?
David Olesch, 2016 5
Give me the codes
Generic Parse Server on Bitbucket
David Olesch, 2016 6
package.js
{
"dependencies": {
"express": "~4.11.x",
"kerberos": "~0.0.x",
"parse": "~1.8.0",
"parse-server": "~2.2.13",
},
"scripts": {
"start": "node index.js"
}
}
David Olesch, 2016 7
index.js
1 of 2
var express = require('express');
var ParseServer = require('parse-server').ParseServer;
var api = new ParseServer({
databaseURI: process.env.DATABASE_URI || 'mongodb://localhost:27017/dev',
cloud: __dirname + '/cloud/main.js',
appId: process.env.APP_ID || 'AppId',
serverURL: process.env.SERVER_URL || 'http://localhost:1337/parse'
]});
var app = express();
David Olesch, 2016 8
index.js
2 of 2
// Serve the Parse API on the /parse URL prefix
var mountPath = process.env.PARSE_MOUNT || '/parse';
app.use(mountPath, api);
var port = process.env.PORT || 1337;
var httpServer = require('http').createServer(app);
httpServer.listen(port, function() {
console.log('parse server running on port ' + port + '.');
});
David Olesch, 2016 9
How do I run it on Heroku?
git push heroku
David Olesch, 2016 10
How do I run it locally?
npm start
David Olesch, 2016 11
How do I add the na,ve SDK to my
iOS app?
David Olesch, 2016 12
Podfile
target 'MyParseApp' do
pod 'Parse'
pod 'ParseUI'
end
David Olesch, 2016 13
AppDelegate.swi-
func application(didFinishLaunchingWithOptions: launchOptions) -> Bool {
Parse.initialize(with: ParseClientConfiguration {
$0.applicationId = 'AppId'
$0.server = 'https://localhost:1337/parse'
})
return true
}
David Olesch, 2016 14

Generic Parse Server

  • 1.
    Parse Server 101 DavidOlesch, 2016 1
  • 2.
    Node.js is easy. Whynot code the server yourself? David Olesch, 2016 2
  • 3.
  • 4.
    How much doesit cost to host Parse Server? David Olesch, 2016 4
  • 5.
    How long doesit take to setup on the back end and front end? David Olesch, 2016 5
  • 6.
    Give me thecodes Generic Parse Server on Bitbucket David Olesch, 2016 6
  • 7.
    package.js { "dependencies": { "express": "~4.11.x", "kerberos":"~0.0.x", "parse": "~1.8.0", "parse-server": "~2.2.13", }, "scripts": { "start": "node index.js" } } David Olesch, 2016 7
  • 8.
    index.js 1 of 2 varexpress = require('express'); var ParseServer = require('parse-server').ParseServer; var api = new ParseServer({ databaseURI: process.env.DATABASE_URI || 'mongodb://localhost:27017/dev', cloud: __dirname + '/cloud/main.js', appId: process.env.APP_ID || 'AppId', serverURL: process.env.SERVER_URL || 'http://localhost:1337/parse' ]}); var app = express(); David Olesch, 2016 8
  • 9.
    index.js 2 of 2 //Serve the Parse API on the /parse URL prefix var mountPath = process.env.PARSE_MOUNT || '/parse'; app.use(mountPath, api); var port = process.env.PORT || 1337; var httpServer = require('http').createServer(app); httpServer.listen(port, function() { console.log('parse server running on port ' + port + '.'); }); David Olesch, 2016 9
  • 10.
    How do Irun it on Heroku? git push heroku David Olesch, 2016 10
  • 11.
    How do Irun it locally? npm start David Olesch, 2016 11
  • 12.
    How do Iadd the na,ve SDK to my iOS app? David Olesch, 2016 12
  • 13.
    Podfile target 'MyParseApp' do pod'Parse' pod 'ParseUI' end David Olesch, 2016 13
  • 14.
    AppDelegate.swi- func application(didFinishLaunchingWithOptions: launchOptions)-> Bool { Parse.initialize(with: ParseClientConfiguration { $0.applicationId = 'AppId' $0.server = 'https://localhost:1337/parse' }) return true } David Olesch, 2016 14