An API to manage our #EddieHub community data.
issue-<issue no>
(e.g. NestJS issue number is 12)Gitpod is a Service, which provides development environments in the cloud. In case no plan is purchased the regular Opensource License
allows to use the service for 50 hours per month for free.
All that needs to be done, is logging in to their service with a valid GitHub account.
README
file. Everything will spin up automatically.$ npm install
When using gitpod, you can set environment-variables under the following link https://gitpod.io/variables
. You can even scope the variable to a specific project.
For connecting the API against the database you can use docker-compose
# database
$ docker-compose up
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod
APPROVED_TOKENS
. npm start
http://localhost:3000/swagger
Official docs at https://docs.nestjs.com/openapi/introduction
# unit tests
$ npm run test
# e2e tests
$ npm run test:e2e
# test coverage
$ npm run test:cov
Logging can be turned on by settings an environment-variable DEBUG=true
.
If this variable is not true or undefined no Logs will be made.
When set to true
the App will Log every incoming request.
Authentication is handled via an environment-variable called APPROVED_TOKENS
.
The approved tokens which are validated by the API are put there.
In case there should be multiple tokens, for multiple clients, they need to be comma-separated.
To use Authentication the token needs to be passed in the token
-header of the client-request.
docker build -t eddiehub-api .
docker run -p 3000:3000 -d eddiehub-api
http://localhost:3000/
docker run -p 3000:3000 -d ghcr.io/eddiehubcommunity/api:latest
http://localhost:3000/
We take participation in our community as a harassment-free experience for everyone and we pledge to act in ways to contribute to an open, welcoming, diverse and inclusive community.
If you have experienced or been made aware of unacceptable behaviour, please remember that you can report this. Read our Code of Conduct.