EduSantosBrito / node-react-docker-boilerplate

A pretty simple boilerplate using Typescript, React and Docker

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Welcome to node-react-docker-boilerplate 👋

Documentation Maintenance Twitter: EduSantosBrito License: MIT

A pretty simple boilerplate using Typescript, React and Docker

🏠 Homepage

Prerequisites

  • npm >=6.10.3
  • node >=12.10.0
  • docker >= 18.09.6
  • docker-compose >= 1.24.1

🚀 Usage

This repository have both production and development mode to build your application. The client folder contains the generated project of create-react-app and a conf folder that is used by production mode with nginx

Development mode

In development mode, we have hot reload. Have fun!

To start developing, clone the repository with:

  git clone https://github.com/EduSantosBrito/node-react-docker-boilerplate.git

Then enter in the project:

  cd node-react-docker-boilerplate

Install dependencies and build client:

  cd client
  npm install
  npm run build

Install dependencies and build server:

  cd server
  npm install
  npm run build

Now we have to build our containers with docker-compose

  docker-compose -f docker-compose.dev.yml up --build

If everything is allright, your front-end application is at localhost:50200, your back-end application is at localhost:50210 and your database is at localhost:50220

  • The mongo image created data folder, this is where your mongo's journal is, so don't delete it!

Production mode

To build your application in production mode, clone the repository with:

  git clone https://github.com/EduSantosBrito/node-react-docker-boilerplate.git

Then enter in the project:

  cd node-react-docker-boilerplate

Now we have to build our containers with docker-compose

  docker-compose -f docker-compose.dev.yml up --build

If everything is allright, your front-end application is at localhost:50100, your back-end application is at localhost:50110 and your database is at localhost:50120

  • The mongo image created data folder, this is where your mongo's journal is, so don't delete it!

Author

👤 Eduardo Santos de Brito

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page.

Show your support

Give a ⭐️ if this project helped you!

📝 License

Copyright © 2019 Eduardo Santos de Brito.
This project is MIT licensed.


This README was generated with ❤️ by readme-md-generator

About

A pretty simple boilerplate using Typescript, React and Docker

License:MIT License


Languages

Language:JavaScript 58.9%Language:HTML 16.3%Language:Dockerfile 13.5%Language:CSS 6.4%Language:TypeScript 4.9%