This repository contains the back-end of our race timing system. It runs on Node.js with the Feathers framework and uses MongoDB for the database.
First, you need Node.js and MongoDB installed on your machine.
For installing Node.js, go to the Node.js download page and get the installer for your platform. Note that we use the LTS version which is the most stable (v8.11.2). Simply follow the instructions of the installer and it should be successfully installed.
To check if it is correctly installed, open a terminal window and launch the following command:
$ node -v
It should display the version of Node.js currently installed on your system.
MongoDB provides a really good guide to install it properly. Follow the instructions given there and you will have MongoDB running in no time !
Once Node.js and MongoDB have been installed, you can clone this repository in any location you want on your computer and install the packages needed.
$ git clone https://github.com/osrts/osrts-backend.git
$ cd osrts-backend
$ npm install
The last command is mandatory as it installs all the packages needed by the server.
To launch the server of the race timing system, use the following command:
$ npm start
You should see an output saying that the Feathers application has started on localhost:3030.
- config/ : contains the configuration files (development.json and production.json)
- src/
- hooks/ : contains the global hooks
- services/ : contains all the services and their hooks
- app.js : initializes the application
- index.js : entry point of the application
- test/
- services/ : tests on all the services
- app.test.js : entry point for all the tests
To run the tests, simply type the following command:
$ mocha
If mocha is not found, you might need to install it globally
$ npm install -g mocha
- Guillaume Deconinck
- Wojciech Grynczel