Git Product home page Git Product logo

nodejs-boilerplate's Introduction

NodeJs Application Boilerplate 🔥 🚀

This is a NodeJs v19.8.x application boilerplate using a Dockerized environment.

Build with

Name Version
NodeJs v19.8.x
Typescript v5.0.x
NPM v9.5.x
Docker v20.10.x
Docker Compose v3.8.x
Redis v6.2.x
Mysql v8.0.x
Postgresql v12.x
MongoDB v3.2.x

Objectives

  • A health start for new applications
  • Easy to maintenance
  • NodeJs learning
  • Docker containers for NodeJs, Redis and multiple databases types like Mysql, Postgresql and MongoDB.

How to use

Install

For start, clone the repository to your local environment. After that, run the following script:

make app-install

This script will build the containers and install the dependencies. After that, the application is ready to use on the url provided for the script.

You only need to make this procedure once.

Starting the application

If you want to start the application, use the following script:

make up

This script will get up all Docker containers, making the application ready to use on the url provided for the script.

Shutting down the application

If you want to stop the application, use the following script:

make down

This script will get down all Docker containers.

About databases

The database options are the following: Mysql, Postgresql and MongoDB. They are commented on the docker-compose file for default. If you want to use one of them, uncomment the related code on the docker-compose file before starting up the application.

After that, you have to develop code to use the database selected, possibly using a ORM (Object Relational Mapper).

What to do from here on?

Now that you have an enviroment ready for your NodeJs application, then you need to start develop the application itself.

Happy coding!

Available Scripts

make help

Show a list of scripts available to help the developer.

make say-hello

Show a welcome message to the developer.

make app-install

Execute the installation of the application, building the containers and installing the dependencies. After the end of the process, the application is ready to use. You only need to run this command once.

make up

Get up all Docker containers.

make down

Get down all Docker containers.

make build

Build images used on the Docker containers.

make stop

Show a list of avaliable Docker containers to stop. You have to select the one that you want to stop.

make in

Show a list of avaliable Docker containers to go inside. You have to select the one that you want to emter.

nodejs-boilerplate's People

Contributors

dehsilvadeveloper avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.