An awesome template to start your projects!
Explore the docs »
A boilerplate to start new scalable projects.
Here's why:
- Your time should be focused on creating something amazing. A project that solves a problem and helps others
- You shouldn't be doing the same tasks over and over like creating all the structure from scratch
- You should element DRY principles to the rest of your life 😄
Of course, no one template will serve all projects since your needs may be different. So I'll be adding more in the near future. You may also suggest changes and modify this template.
A list of commonly used resources that I find helpful are listed in the acknowledgements.
This section list any major frameworks that our boilerplate is using. Leave any add-ons/plugins for the acknowledgements section.
feel free to remove what will not be useful
See here Prerequisites and how to start the project
We mostly recommend to use yarn to manage and install the packages.
-
nodejs see how to install here
-
yarn
npm install yarn@latest -g
You may use sudo if not installed at first
May you see the official docs for install: docs
- Mongo Database using docker
docker run -p 27017:27017 --name mongo-database -d mongo
to install without docker see the docs: Mongo Db installation
- RabbitMq using docker
docker run -d -p 5672:5672 -p 15672:15672 --name rabbitmq-management rabbitmq:3-management
to install without docker see the docs: RabbitMQ installation
- Clone .env.sample to .env and fill variables as needed
- Run
yarn
to install NPM packages
yarn install
- Run dev script with
yarn
yarn start:dev
We recommend to use docker for this.
- Clone .env.sample to .env and fill variables as needed
- Build the docker image
docker build . -t $APP_NAME
- Create/Run the container
docker run -p $PORT:$PORT -d $APP_NAME
Replace $PORT with the app port according to the .env
manually
-
Clone .env.sample to .env and fill variables as needed for the correct environment
-
Build the docker image
docker build . -t $IMAGE_NAME:$VERSION
Replace $IMAGE_NAME and $VERSION as well (note that the image name maybe be the docker repository name as in the deployment.yml)
- Log In your docker cli into ECR (Elastic container registry)
docker login --username {{username}} --password-stdin
- Push the image
docker push $IMAGE_NAME:$VERSION
- Apply the changes
kubectl apply -f deployment.yml
- Confirm that the changes were applied and the pods are up
- you may use
kubectl get pods | grep $APP_NAME
try to see the logs, health check or anything to confirm that is everything okay
Please see the Documentation
While working on this project we recommend to:
- Use Conventional commits
- Use
yarn lint
to validate project code style - Check if the tests are working and add tests as needed
- Check if the build with docker is working
- UPDATE THE DOCS