All services written in TypeScript are hosted under the srv
directory. The
build config, package.json
, etc. are common to all services and each service
is built using make
. The source directories for services are prefixed with
api-
and all the common library code is located under lib
.
A docker-compose.yaml
is provided for local testing and building the Docker
images.
To build all services for local development without using Docker:
$ make
Dependencies can be installed either by running yarn install
manually or
by running the build with make
as the Makefile
will install TS
dependencies too.
- Create a directory for the service
api-<something>
- Add an
index.ts
file undersrc/
in that directory - Add the endpoint to the
ENDPOINTS
list in theMakefile
in this directory - Add the service to the
docker-compose.yaml