service-captcha/docker-compose-prod.yml

96 lines
2.0 KiB
YAML
Raw Permalink Normal View History

version: '3.7'
services:
nginx:
build:
2024-04-25 19:56:34 +05:00
context: ./nginx
dockerfile: Dockerfile
2024-04-25 19:56:34 +05:00
# restart: always
depends_on:
- app
- swagger
ports:
2024-04-25 19:56:34 +05:00
- ${DOCKER_NGINX_PORT}:80
app:
build:
2024-04-25 19:56:34 +05:00
context: app
dockerfile: docker/Dockerfile
target: PRODUCTION
2024-04-25 19:56:34 +05:00
# restart: always
# cap_drop:
# - ALL
# cap_add:
# - SETGID
# - SETUID
# - CHOWN
# - FOWNER
depends_on:
- db
- redis
2024-04-28 01:26:30 +05:00
- reverb
2024-04-25 19:56:34 +05:00
env_file: app/application/.env
2024-04-28 01:26:30 +05:00
queue:
build:
context: app
dockerfile: docker/Dockerfile
target: PRODUCTION
# restart: always
depends_on:
- db
- redis
environment:
CONTAINER_ROLE: queue
volumes:
- ./app/application:/var/www/html
reverb:
build:
context: app
dockerfile: docker/Dockerfile
target: PRODUCTION
# restart: always
depends_on:
- db
- redis
environment:
CONTAINER_ROLE: websockets
ports:
- ${DOCKER_WEBSOCKET_PORT}:9000
volumes:
- ./app/application:/var/www/html
scheduler:
build:
context: app
dockerfile: docker/Dockerfile
target: PRODUCTION
# restart: always
depends_on:
- db
- redis
environment:
CONTAINER_ROLE: scheduler
volumes:
- ./app/application:/var/www/html
swagger:
image: swaggerapi/swagger-ui
2024-04-28 01:26:30 +05:00
# restart: always
depends_on:
- app
environment:
URLS: "[ { url: '/swagger.json', name: '/swagger.json' } ]"
BASE_URL: /api-docs
redis:
image: redis:3.0-alpine
2024-04-28 01:26:30 +05:00
# restart: always
2024-04-25 19:56:34 +05:00
db:
image: docker.io/mysql:8.0.33
command: --default-authentication-plugin=mysql_native_password
#restart: always
ports:
- ${DOCKER_DB_PORT}:3306
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_USER: ${DB_USERNAME}
MYSQL_PASSWORD: ${DB_PASSWORD}
volumes:
- ./db/data:/var/lib/mysql