@@ -52,15 +52,66 @@ let's start with
5252
5353## Usage
5454
55- - You need node .js 18.x or 20.x
55+ - You need Node .js 18.x or higher (24.x preferred)
5656- Fork and clone this repository (optionally subscribe to repo changes)
5757- Run ` npm i ` to install dependencies and generate RSA certificate
5858- Remove unneeded dependencies if your project doesn't require them
5959- Add your license to ` LICENSE ` file but don't remove starter kit license
6060- Start your project modifying this starter kit
61- - If you have Docker and Docker Compose installed to run the project, use the command: ` docker-compose up `
61+ ## Docker Usage
62+
63+ The easiest way to run this application is using Docker and Docker Compose:
64+
65+ ### Prerequisites
66+
67+ - Docker and Docker Compose installed
68+ - No need to install PostgreSQL or Redis locally
69+ - Uses PostgreSQL 17 (latest stable) and Redis 8
70+
71+ ### Quick Start
72+
73+ ``` bash
74+ # Start all services (API, PostgreSQL, Redis)
75+ docker-compose up
76+
77+ # Start services in background (detached mode)
78+ docker-compose up -d
79+
80+ # Stop all services
81+ docker-compose down
82+
83+ # View logs
84+ docker-compose logs
85+
86+ # View logs for specific service
87+ docker-compose logs api-example
88+ docker-compose logs pg-example
89+ docker-compose logs redis-example
90+
91+ # Rebuild and start services
92+ docker-compose up --build -d
93+ ```
94+
95+ ### Access Points
96+ - ** Main Application** : http://localhost:8002/ (Metarhia Console)
97+ - ** API Endpoints** : http://localhost:8001/api/
98+ - ** Load Balancer** : http://localhost:8000/ (redirects to 8002)
99+
100+ ### Service Status
101+
102+ ``` bash
103+ # Check running services
104+ docker-compose ps
105+
106+ # Restart a specific service
107+ docker-compose restart api-example
108+ ```
109+
110+ ## Manual Installation (Alternative)
111+
112+ If you prefer to run without Docker:
62113- Before running server initialize the DB:
63- - First of all, make sure you have PostgreSQL installed (preferably 12 .x to 16 .x).
114+ - First of all, make sure you have PostgreSQL installed (preferably 15 .x to 17 .x).
64115 - Run database initialization script: ` database/setup.sh `
65116- Run project: ` node server.js ` and stop with Ctrl+C
66117- Ask questions in Telegram https://t.me/nodeua (node.js related) or
0 commit comments