Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
91 commits
Select commit Hold shift + click to select a range
6ab881d
fix for Analytics-UI
jignesh248 Sep 1, 2017
2e3bc80
Merge pull request #237 from jignesh248/staging
shubhamqweasd Sep 6, 2017
2fc8ab9
remove masterkey from cloudobject notifications
shubhamqweasd Sep 6, 2017
c987d33
Merge branch 'staging' of https://github.com/CloudBoost/cloudboost in…
shubhamqweasd Sep 6, 2017
8c8bf1d
added node_modules to docker-ignore
shubhamqweasd Sep 6, 2017
a830a99
fix staging issues
shubhamqweasd Sep 6, 2017
75b060e
Update Dockerfile
shubhamqweasd Sep 6, 2017
f448e40
Update .travis.yml
shubhamqweasd Sep 6, 2017
ce844b9
Merge pull request #241 from CloudBoost/staging
shubhamqweasd Sep 6, 2017
1a4cc2b
fix ACL on object notifications
shubhamqweasd Sep 7, 2017
6610ec8
Merge branch 'staging' of https://github.com/CloudBoost/cloudboost in…
shubhamqweasd Sep 7, 2017
73e0eaf
Merge pull request #242 from CloudBoost/staging
shubhamqweasd Sep 7, 2017
5ae90c1
fix masterkey check
shubhamqweasd Sep 7, 2017
31e8379
Merge pull request #244 from CloudBoost/staging
shubhamqweasd Sep 7, 2017
05008ad
cleanup
shubhamqweasd Sep 8, 2017
c5c3151
Merge pull request #247 from CloudBoost/staging
shubhamqweasd Sep 8, 2017
8248991
fix view-break in app authentication page
prabhjotsumman Sep 12, 2017
f1f441a
Merge pull request #248 from Prabhnith/master
shubhamqweasd Sep 12, 2017
15a3fbd
fix in view-break authentication
prabhjotsumman Sep 12, 2017
25c487c
Merge pull request #249 from Prabhnith/master
shubhamqweasd Sep 12, 2017
0242a74
Merge pull request #250 from CloudBoost/staging
shubhamqweasd Sep 13, 2017
d52c7f1
Fixed longString saving error
prabhjotsumman Sep 18, 2017
142a8d5
Merge pull request #251 from Prabhnith/master
shubhamqweasd Sep 18, 2017
6a0e1b0
fix analytics
shubhamqweasd Sep 18, 2017
b120ea3
Merge branch 'staging' of https://github.com/CloudBoost/cloudboost in…
shubhamqweasd Sep 18, 2017
80b2e5b
fix auth pages
shubhamqweasd Sep 19, 2017
6563785
Merge pull request #252 from CloudBoost/staging
shubhamqweasd Sep 20, 2017
783c518
change to api
shubhamqweasd Sep 22, 2017
0c7314e
Merge pull request #254 from CloudBoost/staging
shubhamqweasd Sep 22, 2017
f6ca798
Merge pull request #255 from CloudBoost/master
nawazdhandala Sep 24, 2017
858c644
Update README.md
nawazdhandala Sep 24, 2017
ead6b29
Update README.md
nawazdhandala Sep 24, 2017
ff16e17
Merge pull request #256 from CloudBoost/staging
nawazdhandala Sep 24, 2017
dbb8631
Update README.md
nawazdhandala Sep 24, 2017
472dba6
Staging (#268)
shubhamqweasd Oct 31, 2017
a49336a
Staging (#270)
shubhamqweasd Nov 1, 2017
d9cfa45
Update package.json
shubhamqweasd Nov 9, 2017
69add80
fix realtime duplicate events
shubhamqweasd Nov 9, 2017
65d64ca
added letsencrypt certs
shubhamqweasd Nov 10, 2017
ed2b33b
cert fix
shubhamqweasd Nov 10, 2017
a2b89b5
run on https only with certs and production env
shubhamqweasd Nov 13, 2017
a644762
increase poolSize for mongoclient
shubhamqweasd Nov 20, 2017
0839be5
mongodb conn string
shubhamqweasd Nov 20, 2017
0e0737b
remove certs
shubhamqweasd Nov 21, 2017
5325c73
Merge branch 'staging' of https://github.com/CloudBoost/cloudboost in…
shubhamqweasd Nov 21, 2017
c6ef737
Staging (#274)
shubhamqweasd Nov 21, 2017
2f8be3d
fix: package.json & .snyk to reduce vulnerabilities
Nov 21, 2017
c2eb72c
Merge pull request #275 from CloudBoost/snyk-fix-56a525c6
admincloudboost Nov 21, 2017
75e31e4
Encryption (#272)
andyRocks16 Nov 27, 2017
69d8ab3
Staging (#276)
shubhamqweasd Nov 27, 2017
9d144af
use legacy node
shubhamqweasd Nov 28, 2017
45ffe73
enable both http and https at same time
shubhamqweasd Dec 6, 2017
f2d0fa7
Staging (#277)
shubhamqweasd Dec 6, 2017
51c5796
kube redis cluster config
shubhamqweasd Dec 22, 2017
643c177
Update README.md
shubhamqweasd Dec 22, 2017
90f86f9
fix travis
shubhamqweasd Jan 1, 2018
9adacb5
Merge branch 'staging' of https://github.com/CloudBoost/cloudboost in…
shubhamqweasd Jan 1, 2018
efbb23a
remove export data limit
shubhamqweasd Jan 4, 2018
f666664
Staging (#281)
shubhamqweasd Jan 4, 2018
1609d34
Update .travis.yml
shubhamqweasd Jan 4, 2018
3060dcc
EmalToTargetUsers
rravithejareddy Jan 16, 2018
61c6a2b
changed query parameter position
rravithejareddy Jan 16, 2018
9ae21d1
changed query parameter position
rravithejareddy Jan 16, 2018
42e1ee7
Merge pull request #287 from rravithejareddy/EmailsToTargetUsers
nawazdhandala Jan 16, 2018
934232f
Removed Cloud Queues and Cache
UtkarshPramodGupta Feb 15, 2018
bcbea9d
Removed Cluster Registration Failed error from logging on the console
UtkarshPramodGupta Feb 15, 2018
fa8893f
Merge branch 'staging' into master
nawazdhandala Feb 15, 2018
4dd73ed
Merge pull request #298 from UtkarshPramodGupta/master
nawazdhandala Feb 15, 2018
60580a7
Removed CloudPush service
UtkarshPramodGupta Feb 15, 2018
b182c23
Merge branch 'master' of https://github.com/UtkarshPramodGupta/cloudb…
UtkarshPramodGupta Feb 15, 2018
c8c084f
Merge pull request #299 from UtkarshPramodGupta/master
nawazdhandala Feb 15, 2018
ac100c4
Merge pull request #300 from CloudBoost/master
nawazdhandala Feb 15, 2018
54832ad
Cluster Registration removed.
nawazdhandala Mar 22, 2018
9bdbf33
Merge remote-tracking branch 'origin/staging' into staging
nawazdhandala Mar 22, 2018
c7b87fa
JavaScript SDK Merged with CloudBoost
nawazdhandala Mar 22, 2018
947267d
JavaScript SDK Merge complete.
nawazdhandala Mar 22, 2018
151a02f
Added a new version of JavaScript SDK.
nawazdhandala Mar 22, 2018
fba7745
Column Name bug fixed.
nawazdhandala Mar 24, 2018
e315eee
Grunt file modified.
nawazdhandala Mar 25, 2018
adb6d16
Clone fixed in the SDK.
nawazdhandala Mar 25, 2018
d50a7f7
Readme Updated.
nawazdhandala Mar 25, 2018
0a9954b
Supported String datatype error fixed.
nawazdhandala Mar 25, 2018
f7b4f1b
Tests uncommented.
nawazdhandala Mar 25, 2018
7a36d81
LocalStorage Fixed.
nawazdhandala Mar 26, 2018
94f0663
Removed all console.logs.
nawazdhandala Mar 26, 2018
0cbcc87
LocalStorage fixed.
nawazdhandala Mar 26, 2018
7c2b714
LocalStorage fixed on NodeJS
nawazdhandala Mar 26, 2018
f5f255a
LocalStorage on NodeJS
nawazdhandala Mar 26, 2018
7152c6f
Added Secure Key helper message.
nawazdhandala Mar 26, 2018
05f0006
Fixed SDK
nawazdhandala Mar 26, 2018
0643ea5
Added NPM Ignore for SDK NPM Publish
nawazdhandala Mar 26, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
.git/
#node_modules/
node_modules/
config/cloudboost.json
.vscode/
*.suo
Expand Down
17 changes: 17 additions & 0 deletions .snyk
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Snyk (https://snyk.io) policy file, patches or ignores known vulnerabilities.
version: v1.8.0
ignore: {}
# patches apply the minimum changes required to fix a vulnerability
patch:
'npm:debug:20170905':
- nodemailer-mailgun-transport > mailgun-js > debug:
patched: '2017-11-21T04:47:12.009Z'
'npm:ms:20170412':
- nodemailer-mailgun-transport > mailgun-js > debug > ms:
patched: '2017-11-21T04:47:12.009Z'
'npm:qs:20140806-1':
- winston-bishop-slack > winston > request > qs:
patched: '2017-11-21T04:47:12.009Z'
'npm:request:20160119':
- winston-bishop-slack > winston > request:
patched: '2017-11-21T04:47:12.009Z'
28 changes: 18 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,20 @@ install:
fi
- docker run --name cloudboost -e MAIL_PROVIDER=$MAIL_PROVIDER -e MAIL_PROVIDER_API_KEY=$MAIL_PROVIDER_API_KEY -e DOMAIN=$DOMAIN -e FROM_EMAIL=$FROM_EMAIL -e FROM_NAME=$FROM_NAME -p 4730:4730 -it --link redis:redis --link mongo:mongo -d cloudboost/cloudboost:2.0.$TRAVIS_BUILD_NUMBER
- sleep 30s
- git clone https://github.com/cloudboost/javascriptsdk
- cd javascriptsdk
- npm install
- docker logs cloudboost
- webpack
- grunt
- npm test
- cd ..
after_success:
- if [ "$TRAVIS_BRANCH" == "staging" ]; then
docker login --username $DOCKERUSERNAME --password $DOCKERPASSWORD --email $DOCKEREMAIL;
docker login --username $DOCKERUSERNAME --password $DOCKERPASSWORD;
docker push cloudboost/cloudboost:staging;
git clone https://github.com/CloudBoost/kube-cred.git;
cd kube-cred;
openssl enc -in config.enc -out config -d -aes256 -k $KUBE_ENC;
openssl enc -in config_staging.enc -out config -d -aes256 -k $KUBE_ENC;
mkdir ~/.kube;
mv config ~/.kube/;
kubectl rolling-update cloudboost-engine-staging --image=cloudboost/cloudboost:staging --image-pull-policy=Always;
kubectl rolling-update cloudboost-api-staging --image=cloudboost/cloudboost:staging --image-pull-policy=Always;
fi
before_deploy:
- git config --global user.email "builds@travis-ci.com"
Expand All @@ -62,19 +60,29 @@ deploy:
after_deploy:
# Docker Deploy.
- if [ "$TRAVIS_BRANCH" == "master" ]; then
docker login --username $DOCKERUSERNAME --password $DOCKERPASSWORD --email $DOCKEREMAIL;
docker login --username $DOCKERUSERNAME --password $DOCKERPASSWORD;
docker push cloudboost/cloudboost:2.0.$TRAVIS_BUILD_NUMBER;
docker push cloudboost/cloudboost:latest;
git clone https://github.com/CloudBoost/kube-cred.git;
cd kube-cred;
openssl enc -in config.enc -out config -d -aes256 -k $KUBE_ENC;
mkdir ~/.kube;
mv config ~/.kube/;
kubectl rolling-update cloudboost-engine --image=cloudboost/cloudboost:latest --image-pull-policy=Always;
kubectl rolling-update cloudboost-api --image=cloudboost/cloudboost:latest --image-pull-policy=Always;
# publish to npm
cd sdk
npm install
npm set init.author.name $NPM_USERNAME
npm set init.author.email $NPM_EMAIL
npm set init.author.url "https://cloudboost.io"
npm --no-git-tag-version version 2.0.$TRAVIS_BUILD_NUMBER --force
echo -e "$NPM_USERNAME\n$NPM_PASSWORD\n$NPM_EMAIL" | npm login
sleep 10s
npm publish
fi
branches:
except:
- /^*-v[0-9]/
#Notify Team on Slack
notifications:
slack: cloudboost:gm7nWJDLDtBRyF75VKLKOoMW
slack: hackerbaycompany:gm7nWJDLDtBRyF75VKLKOoMW
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# CloudBoost Dockerfile
#
# Pull base image nodejs image.
FROM node:7.5.0
FROM node:6.12.0

#Maintainer.
MAINTAINER Nawaz Dhandala <nawazdhandala@outlook.com>
Expand Down
82 changes: 76 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
<img src="https://www.dropbox.com/s/7ghf1kl7crp5bvy/CbLogoIcon.png?raw=1" height="80" />
<img src="https://www.dropbox.com/s/gpdhpr3c63dquby/CLoudBoostLogo-Circle-250.png?dl=0&raw=1" height="150" style="text-align: center;" />

[![Build Status](https://travis-ci.org/CloudBoost/cloudboost.svg?branch=master)](https://travis-ci.org/CloudBoost/cloudboost)
[![OpenCollective](https://opencollective.com/cloudboost/backers/badge.svg)](#backers)

CloudBoost is the complete serverless platform for your app. **Think of CloudBoost as Parse + Firebase + Algolia + Iron.io all combined into one** :
CloudBoost is the complete cloud platform for your app. **Think of CloudBoost as Parse + Firebase + Algolia + Iron.io all combined into one** :
- Data-Storage / JSON Storage / BLOB Storage
- 100% data ownership
- Realtime
- Search
- Cache
- Queues
- More - ACL's, User Authentication, Server-less apps and more.
- Search
- More - ACL's, User Authentication, and more.

CloudBoost also has a [managed service](https://www.cloudboost.io), so you don't have to install or configure anything. You can sign up for the managed service [here.](https://www.cloudboost.io)


## Deploy with Docker (recommended)
Expand Down Expand Up @@ -137,6 +136,73 @@ Once your app is ready, You can then get the latest SDK from https://tutorials.

You can then follow rest of the documentation from https://tutorials.cloudboost.io. You can also check out API Reference on https://docs.cloudboost.io

## JavaScript SDK

JavaScript SDK can be found in the `sdk` folder of this repo.

### NPM Installation
```
npm install cloudboost
```

### NodeJS Usage

``` js

var CB = require('cloudboost');

```

### Bower Installation
```
bower install cloudboost
```

### JavaScript Usage

``` js
<script src="bower_components/cloudboost/dist/cloudboost.js"></script>
```

### Module Bundlers

``` js
// For ES6/ES7 , TypeScript(typings included)
import * as CB from 'cloudboost';

//For ES5 (requireJs)
var CB = require('cloudboost');

```

### Sample Code

``` js

// AppID and AppKey are your App ID and key of the application created in CloudBoost Dashboard.

//Init your Application
CB.CloudApp.init('YourAppId','YourAppKey');

//Data Storage : Create a CloudObject of type 'Custom' (Note: You need to create a table 'Custom' on CloudBoost Dashboard)

var obj = new CB.CloudObject('Custom');

//Set the property 'name' (Note: Create a column 'name' of type text on CloudBoost Dashboard)
obj.set('name','CloudBoost');

//Save the object
obj.save({
success:function(res){
console.log("object saved successfully");
},
error:function(err){
console.log("error while saving object");
}
});

```

## Cluster Maintenance, Scale, and Updates

CloudBoost runs on MongoDB and Redis. You're responsible for managing the [uptime](https://en.wikipedia.org/wiki/Uptime), [replication](https://en.wikipedia.org/wiki/Replication_(computing)), [sharding](https://en.wikipedia.org/wiki/Shard_(database_architecture)), [backups](https://en.wikipedia.org/wiki/Backup) of your data in each of these databases.
Expand All @@ -156,6 +222,10 @@ To read more about app settings, check [Click here](https://github.com/CloudBoos
- Email: [support@cloudboost.io](support@cloudboost.io)
- Twitter: [@cloudboostio](https://twitter.com/cloudboostio)

# Tests

Tests are in a seperate repository. You can find them [here.](https://www.github.com/cloudboost/javascriptsdk)

# Contributing

[Pull requests](https://help.github.com/articles/about-pull-requests/) are very welcome!
Expand Down
34 changes: 17 additions & 17 deletions api/app/Admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,63 +8,63 @@ module.exports = function() {

//Change MasterKey/ClientKey
global.app.put('/admin/:appId/clientkey',function(req, res) {
console.log("++++ Change ClientKey ++++++");


try{

var appId = req.params.appId;

if (global.keys.secureKey === req.body.secureKey) {
console.log("Secure Key Valid. Changing ClientKey...");


global.appService.changeAppClientKey(appId,req.body.value).then(function (app){
console.log("Success : Changing ClientKey.");

res.status(200).json(app);
}, function (err){
console.log("Error : Changing ClientKey.");
console.log(err);


res.status(500).send("Error");
});

} else {
console.log("Unauthorized: Invalid Secure Key ");

res.status(401).send("Unauthorized");
}


}catch(e){
console.log(e);

}
});

//Change MasterKey/ClientKey
global.app.put('/admin/:appId/masterkey',function(req, res) {
console.log("++++ Change Masterkey ++++++");


try{

var appId = req.params.appId;

if (global.keys.secureKey === req.body.secureKey) {
console.log("Secure Key Valid. Changing Masterkey...");


global.appService.changeAppMasterKey(appId,req.body.value).then(function (app){
console.log("Success : Changing Masterkey.");

res.status(200).json(app);
}, function (err){
console.log("Error : Changing Masterkey.");
console.log(err);


res.status(500).send("Error");
});

} else {
console.log("Unauthorized: Invalid Secure Key ");

res.status(401).send("Unauthorized");
}


}catch(e){
console.log(e);

}
});

Expand All @@ -78,7 +78,7 @@ module.exports = function() {
-Error : Error Data( 'Server Error' : status 500 )
*/
global.app.post('/admin/dbaccess/enable/:appId',function(req, res) {
console.log("++++ MongoDb Native Access ++++++");

try {
if (global.keys.secureKey === req.body.secureKey) {
global.appService.createDatabaseUser(req.params.appId).then(function (userData){
Expand All @@ -87,12 +87,12 @@ module.exports = function() {
res.status(500).send("Server Erorr");
});
} else {
console.log("Unauthorized: Invalid Secure Key ");

res.status(401).send("Unauthorized");
}

} catch(e){
console.log(e);

}
});
};
Loading