remove nginx and postgres
This commit is contained in:
32
.env.example
32
.env.example
@@ -1,26 +1,26 @@
|
|||||||
PROJECT_NAME=""
|
PROJECT_NAME="crm"
|
||||||
|
|
||||||
LARAVEL_PROJECT_PATH="./laravel"
|
LARAVEL_PROJECT_PATH="./backend"
|
||||||
|
|
||||||
POSTGRES_USER=""
|
POSTGRES_USER=""
|
||||||
POSTGRES_DB=""
|
POSTGRES_DB=""
|
||||||
POSTGRES_PASSWORD=""
|
POSTGRES_PASSWORD=""
|
||||||
|
|
||||||
NOTIFICATION_SERVER_PATH=""
|
NOTIFICATION_SERVER_PATH="./notification_server"
|
||||||
NOTIFICATION_SERVICE_URL=""
|
NOTIFICATION_SERVICE_URL="http://host.docker.internal:8888/server"
|
||||||
NOTIFICATION_SERVER_DB=""
|
NOTIFICATION_SERVER_DB="notification_db"
|
||||||
NOTIFICATION_SERVER_USER=""
|
NOTIFICATION_SERVER_USER="notification_user"
|
||||||
NOTIFICATION_SERVER_PASSWORD=""
|
NOTIFICATION_SERVER_PASSWORD="1qaz@WSX"
|
||||||
NOTIFICATION_SERVER_DB_SSL=""
|
NOTIFICATION_SERVER_DB_SSL="false"
|
||||||
NOTIFICATION_SERVER_DB_SYNC=""
|
NOTIFICATION_SERVER_DB_SYNC="true"
|
||||||
NOTIFICATION_SERVER_PORT=""
|
NOTIFICATION_SERVER_PORT="3023"
|
||||||
|
|
||||||
REDIS_HOST=""
|
REDIS_HOST=redis
|
||||||
REDIS_PORT=""
|
REDIS_PORT=6379
|
||||||
|
|
||||||
NEXT_JS_PATH=""
|
NEXT_JS_PATH="./frontend"
|
||||||
NEXT_PUBLIC_VERSION=""
|
NEXT_PUBLIC_VERSION="2.3.0"
|
||||||
NEXT_PUBLIC_API_URL=""
|
NEXT_PUBLIC_API_URL="http://host.docker.internal:8888/server"
|
||||||
NEXT_PUBLIC_SERVER_SOCKET_URL=""
|
NEXT_PUBLIC_SERVER_SOCKET_URL="wss://192.168.1.20:8888"
|
||||||
|
|
||||||
NGINX_CONFIG_PATH=""
|
NGINX_CONFIG_PATH=""
|
||||||
@@ -1,36 +1,23 @@
|
|||||||
services:
|
services:
|
||||||
nginx:
|
# backend_db:
|
||||||
image: nginx:1.27.5-alpine3.21
|
# image: postgres:17-alpine3.21
|
||||||
container_name: nginx
|
# container_name: backend_db
|
||||||
restart: always
|
# tty: true
|
||||||
tty: true
|
# ports:
|
||||||
ports:
|
# - "8050:5432"
|
||||||
- "8888:80"
|
# environment:
|
||||||
volumes:
|
# POSTGRES_DB: ${POSTGRES_DB}
|
||||||
- ${NGINX_CONFIG_PATH}:/etc/nginx/conf.d
|
# POSTGRES_USER: ${POSTGRES_USER}
|
||||||
- ${NGINX_CONFIG_PATH}/logs:/var/log/nginx/
|
# POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||||
|
# volumes:
|
||||||
|
# - ./data:/var/lib/postgresql/data
|
||||||
backend_db:
|
# profiles:
|
||||||
image: postgres:17-alpine3.21
|
# - server
|
||||||
container_name: backend_db
|
# networks:
|
||||||
tty: true
|
# - crm_network
|
||||||
ports:
|
|
||||||
- "8050:5432"
|
|
||||||
environment:
|
|
||||||
POSTGRES_DB: ${POSTGRES_DB}
|
|
||||||
POSTGRES_USER: ${POSTGRES_USER}
|
|
||||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
||||||
volumes:
|
|
||||||
- ./data:/var/lib/postgresql/data
|
|
||||||
profiles:
|
|
||||||
- server
|
|
||||||
networks:
|
|
||||||
- crm_network
|
|
||||||
|
|
||||||
|
|
||||||
notification_db:
|
notification_db:
|
||||||
image: postgres:17-alpine3.21
|
image: docker.arvancloud.ir/postgres:17-alpine3.21
|
||||||
container_name: notification_db
|
container_name: notification_db
|
||||||
tty: true
|
tty: true
|
||||||
ports:
|
ports:
|
||||||
@@ -47,7 +34,7 @@ services:
|
|||||||
- crm_network
|
- crm_network
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
image: redis:7-alpine3.21
|
image: docker.arvancloud.ir/redis:7-alpine3.21
|
||||||
container_name: redis
|
container_name: redis
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
tty: true
|
tty: true
|
||||||
@@ -65,13 +52,21 @@ services:
|
|||||||
ports:
|
ports:
|
||||||
- "9000:9000"
|
- "9000:9000"
|
||||||
volumes:
|
volumes:
|
||||||
- ${LARAVEL_PROJECT_PATH}:/var/www/laravel
|
- ${LARAVEL_PROJECT_PATH}:/var/www/crm/backend
|
||||||
|
extra_hosts:
|
||||||
|
- "host.docker.internal:host-gateway" # Enables host DB access
|
||||||
|
environment:
|
||||||
|
# Host DB connection
|
||||||
|
DB_CONNECTION: mysql
|
||||||
|
DB_HOST: host.docker.internal
|
||||||
|
DB_PORT: 3306
|
||||||
|
DB_DATABASE: roaddb
|
||||||
|
DB_USERNAME: root
|
||||||
|
DB_PASSWORD: WitelDB
|
||||||
profiles:
|
profiles:
|
||||||
- server
|
- server
|
||||||
networks:
|
networks:
|
||||||
- crm_network
|
- crm_network
|
||||||
depends_on:
|
|
||||||
- backend_db
|
|
||||||
|
|
||||||
|
|
||||||
notification_server:
|
notification_server:
|
||||||
@@ -92,19 +87,14 @@ services:
|
|||||||
- PORT=${NOTIFICATION_SERVER_PORT}
|
- PORT=${NOTIFICATION_SERVER_PORT}
|
||||||
- REDIS_HOST=${REDIS_HOST}
|
- REDIS_HOST=${REDIS_HOST}
|
||||||
- REDIS_PORT=${REDIS_PORT}
|
- REDIS_PORT=${REDIS_PORT}
|
||||||
|
extra_hosts:
|
||||||
|
- "host.docker.internal:host-gateway"
|
||||||
ports:
|
ports:
|
||||||
- "3023:${NOTIFICATION_SERVER_PORT}"
|
- "3023:${NOTIFICATION_SERVER_PORT}"
|
||||||
volumes:
|
|
||||||
- ${NOTIFICATION_SERVER_PATH}:/var/www/notification_server
|
|
||||||
profiles:
|
profiles:
|
||||||
- server
|
- build
|
||||||
networks:
|
networks:
|
||||||
- crm_network
|
- crm_network
|
||||||
depends_on:
|
|
||||||
- backend_db
|
|
||||||
- laravel
|
|
||||||
- notification_db
|
|
||||||
- redis
|
|
||||||
|
|
||||||
nextjs:
|
nextjs:
|
||||||
build:
|
build:
|
||||||
@@ -112,14 +102,14 @@ services:
|
|||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
container_name: nextjs
|
container_name: nextjs
|
||||||
env_file:
|
env_file:
|
||||||
- ${NEXT_JS_PATH}/.env.local
|
- ${NEXT_JS_PATH}/.env
|
||||||
volumes:
|
|
||||||
- ${NEXT_JS_PATH}:/var/www/nextjs
|
|
||||||
ports:
|
ports:
|
||||||
- "3106:3000"
|
- "3106:3000"
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
extra_hosts:
|
||||||
|
- "host.docker.internal:host-gateway"
|
||||||
profiles:
|
profiles:
|
||||||
- server
|
- build
|
||||||
networks:
|
networks:
|
||||||
- crm_network
|
- crm_network
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user