The backbone of echo karriere
Table of Contents
Table of Contents
This is the backend that powers echo karriere for managing our events, content and data. It's a student developed project written in TypeScript using NestJS, Prisma and Azure.
Run yarn
to install everything you need. Once that's done run node scripts/build-info
to generate
some metadata that is used for quering the status of the application. NB: You'll only ever need to
do this once.
You should look over the
documentation if you haven't already for installing Docker and
configuring IntelliJ. Create a copy of the env.example
file called .env
, to get the Azure credentials ask the webmaster.
NB: The .env
file is ignored by git
by default so that we never accidentally expose secrets, make sure you never
commit this file to the repositiory!
Once you've created the .env
file you and are ready to develop, run:
docker-compose -f docker-compose.yml -f docker-compose.test.yml up -d
to start the development and test server for. We use two different instances of PostgreSQL to avoid conflicts and errors when running tests and a live development server.
NOTE: On your first lauch you need to do AZURE_RELOAD=on yarn start:dev
to fetch and populate the users
and roles from Azure. You'll only need to run this the first time you clone this repository, or whenever the
database is cleared.
To run the application you can either start it with yarn start:dev
or run it from your IDE.
# development
$ yarn start
# watch mode
$ yarn start:dev
# production mode
$ yarn start:prod
# unit tests
$ yarn test
# e2e tests
$ yarn test:e2e
# test coverage
$ yarn test:cov
MIT.