1
0
mirror of https://gitlab.com/MoonTestUse1/AdministrationItDepartmens.git synced 2025-08-14 00:25:46 +02:00
This commit is contained in:
MoonTestUse1
2024-12-26 01:37:55 +06:00
parent 5020ac3a37
commit 06b778cb6e
2 changed files with 22 additions and 12 deletions

View File

@@ -1,3 +1,5 @@
version: '3.8'
services: services:
frontend: frontend:
build: build:
@@ -5,6 +7,8 @@ services:
dockerfile: docker/frontend/Dockerfile dockerfile: docker/frontend/Dockerfile
container_name: support-frontend container_name: support-frontend
restart: unless-stopped restart: unless-stopped
networks:
- app-network
depends_on: depends_on:
- backend - backend
@@ -12,7 +16,7 @@ services:
build: build:
context: . context: .
dockerfile: docker/backend/Dockerfile dockerfile: docker/backend/Dockerfile
container_name: backend container_name: support-backend
environment: environment:
- TELEGRAM_BOT_TOKEN=7677506032:AAHEqNUr1lIUfNVbLwaWIaPeKKShsCyz3eo - TELEGRAM_BOT_TOKEN=7677506032:AAHEqNUr1lIUfNVbLwaWIaPeKKShsCyz3eo
- TELEGRAM_CHAT_ID=-1002037023574 - TELEGRAM_CHAT_ID=-1002037023574
@@ -23,16 +27,18 @@ services:
- app-network - app-network
nginx: nginx:
build: build:
context: . context: .
dockerfile: docker/nginx/Dockerfile dockerfile: docker/nginx/Dockerfile
container_name: support-nginx container_name: support-nginx
restart: unless-stopped restart: unless-stopped
ports: ports:
- "80:80" - "80:80"
depends_on: networks:
- frontend - app-network
- backend depends_on:
- frontend
- backend
networks: networks:
app-network: app-network:

View File

@@ -1,3 +1,7 @@
upstream backend_upstream {
server support-backend:8000;
}
server { server {
listen 80 default_server; listen 80 default_server;
listen [::]:80 default_server; listen [::]:80 default_server;
@@ -17,7 +21,7 @@ server {
# API proxy # API proxy
location /api/ { location /api/ {
proxy_pass http://backend:8000; proxy_pass http://backend_upstream;
proxy_http_version 1.1; proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade; proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade'; proxy_set_header Connection 'upgrade';