Skip to content

hackthievist/sterling-fixtures

Repository files navigation

STERLING FIXTURES

Sterling Fixtures API

Installation

These instructions are for use without docker

yarn install

Documentation

  • The API documentation with Postman can be found here

Starting App

  • To run the app, copy the file .env.example to .env and substitute the settings to match your development environment.
  • Make sure mongo, redis and elasticsearch are installed and running if you plan on using them locally.
  • Start the app with yarn:
yarn start
  • Navigate to localhost:3000. Please note 3000 is the default port used, you can change this in .env.

Testing

  • Tests are written using the Jest library.
  • To run tests with yarn use:
yarn test

Docker

Using Docker Standalone - Compose (Recomended for local development)

  • Copy the files docker-config/secrets.env.example, docker-config/config.env.example to docker-config/secrets.env, docker-config/config.env and substitute the settings to match your development environment.

Make sure mongodb is installed and running with IP bound to docker service mongo

mongod --bind_ip mongo
docker-compose up -d
  • see logs
docker-compose logs -f
  • run tests
docker-compose run --rm fixtures-api_web yarn test
  • tear down
docker-compose down

Visit App

Tests

  • There are 3 test suites, with 52 test cases for Fixture, Team and User. They can be found in tests/

Stack

  • Backend Language + Framework: Nodejs + Express
  • Database: MongoDB
  • Testing Framework: Jest
  • Hosting Server: Heroku
  • Container Platform: Docker
  • Session Management: Redis
  • Authentication/Authorization: Bearer Token/JWT
  • Dynamic Link Generator: Firebase Dynamic Links

Extras

  • Rate Limit: Requests to the fixtures-api are limited to 50 per 15 minutes.

About

Fixtures API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages