Skip to content

hmarsolla/ecommerce-backend

Repository files navigation

ecommerce-backend

This project was developed as an example of how to create a simple Typescript backend implementation with these key features in mind:

  • RESTful API
  • MongoDB Communication
  • JWT Authentication
  • Swagger documentation setup
  • Automated tests with Jest
  • Dockerfile for ease of deployment
  • Github Actions CI/CD steps

How To Run

  1. Locally

This project was developed using Node version ^20.12 To run, simply execute the following commands:

npm install
npm start
  1. Dockerfile

You can also run via the included Docker image:

docker build -t ecommerce-backend .
docker run -ti -p 3000:3000 ecommerce-backend

Tests

This project can be tested with Jest by running the following command:

npm test

The Github Actions pipeline will ensure that each commit will be tested before any release.

API Documentation

When the project is running, access the Swagger Documentation in the /api-docs route.

TODO:

  • Dockerhub publish step in Github Actions

About

A sample of an E-commerce Backend using Typescript

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published