Service to accept heartbeat and data information and store it
- Fork the repository
- Run
git clone https://github.com/<username>/koma
to clone the repository - Run
cd koma
, thennpm install
- Setup your Firebase database
- Create a Firebase project with Realtime Database
- In the Realtime Database panel, add a new key-value pair
"Test": "Test"
. You can remove this later after the database is populated with some actual data. If you don't add some initial data, the database won't be saved and you'll have to create another new one. - Edit the Realtime Database rules, replacing with the contents of
firebase-rules.json
- In the
Authentication -> Sign-in Method
panel, enable the Email/Password provider and configure any authorized domains
- Setup configurations
- Initialize your MySql database by running
npm run initTestDB
- Copy
default-example.json
file todefault.json
. - Replace
firebase.databaseUrl
with the URL to your Firebase database. - Replace
firebase.serviceAccount
with the Service Account which is downloaded in Firebase underneathProject Settings -> Service Accounts -> Firebase Admin SDK -> Generate New Private Key
We use apidoc.js for API Documenation.
To generate documentation, run the command apidoc -i src/ -o docs/
. This command will
generate all documentation for files underneath the src/
directory and generate the documentation
in the docs/
folder. The npm build
command will also generate the documentation.
For deployment instructions, please see the DEPLOYMENT.md document.