Simple reverse-proxy server based on Nginx NodeJS and PostgreSQL.
NodeJS part of this project is based on nodejs-koa-boilerplate
Use these steps to install project
- Install Docker: https://www.docker.com/
- Build project:
docker-compose build
- Run docker-compose:
docker-compose up -d
- Stop containers:
docker-compose down
For local development (NodeJS) pass variables in .env file and use local PostgreSQL database (you can use official Docker container).
This boilerplate contains such folders:
- /src - main sources folder.
- /src/constants - app constants.
- /src/controllers - contain controllers that receives requests from routes, executes business logic via services and returns responses to client.
- /src/db - contain scripts to setup and manage database
- /src/middleware - app middlewares
- /src/entities - database entities
- /src/services - services contains logic to manage database, execute requests to other servers, change application behabior, and etc.
- /src/app.js - app configuration
- /src/index.js - contain main scripts that configures and run server
- /test - contains tests for controllers, services and other parts of application.
- start - run dev server using nodemon
- build - build project
- serve - run built files
- Docker
- NodeJS
- Nginx
- PostgreSQL
- KoaJS
- Babel
- jsonwebtoken
- typeorm
- awilix
- awilix-koa
- koa-bodyparser
- koa-cookie
- koa-router
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D
Vlad Morzhanov
Copyright (c) 2018 Vlad Morzhanov. You can review license in the LICENSE file.