This is the server part of the loop project. You can find more information on its APIs by looking at the online documentation
You will need redis-server installed:
apt-get install redis-server
or
yum install redis
Assuming you have brew installed, use it to install redis:
brew install redis
If you need to restart it (after configuration update):
brew services restart redis
Then clone the loop server and install its dependencies:
git clone https://github.com/mozilla/loop-server.git
cd loop-server && make install
You can create your configuration file in config/{NODE_ENV}.json
dev
is the environment by default. In order to run the server, you'll need to
create a dev.json
file in the config folder. You can do so by using this
command:
cp config/{sample,dev}.json
Be sure to edit the content of config/dev.json
. You'll especially need to
specify your tokbox credentials.
Once that's done, you can do:
make runserver
(which is equivalent to NODE_ENV=dev make runserver
)
make test
Redis is the default backend. The code is made to support multiple ones but only supports redis for now.
You should report bugs/issues or feature requests via the loop-server bugzilla component
usage = nbUsers * 280 + nbCallsPerDay * 1365 + nbUrlRevocationPerMonth * 150 + 600000 (bytes)
- For 10M users and 100 000 calls a day we will need around 2.7 GB
- For 250M users and 10M calls a day we will need around 78 GB
The biggest AWS Elasticache Redis virtual machine is 68GB large so if we want to handle more that 150M users we will probably want to do some sharding to have one redis for calls and another one for user management.
The Loop server code is released under the terms of the
Mozilla Public License v2.0. See the
LICENSE
file at the root of the repository.