Разделение конфигов php, мелочи по compose.yml

This commit is contained in:
2025-03-15 20:56:18 +08:00
parent 1b055797d6
commit 31fa1a0f5a
7 changed files with 47 additions and 29 deletions

View File

@@ -2,63 +2,57 @@ networks:
iptv:
driver: bridge
x-common-attributes: &common-attributes
restart: unless-stopped
env_file:
- .env
extra_hosts:
- host.docker.internal:host-gateway
volumes:
- /etc/localtime:/etc/localtime:ro
- /etc/timezone:/etc/timezone:ro
networks:
- iptv
services:
keydb:
<<: *common-attributes
container_name: iptv-keydb
image: eqalpha/keydb:latest
user: "${REDIS_UID}:${REDIS_GID}"
restart: unless-stopped
volumes:
- /etc/localtime:/etc/localtime:ro
- ./docker/keydb/keydb.conf:/etc/keydb/keydb.conf
- ./docker/keydb/data/:/data:rw
- ./log/keydb:/var/log/keydb/:rw
env_file:
- .env
ports:
- "${REDIS_PORT:-6379}:6379"
networks:
- iptv
php:
<<: *common-attributes
container_name: iptv-php
env_file:
- .env
environment:
- PHP_IDE_CONFIG=serverName=iptv.local
build:
dockerfile: docker/php/${IPTV_ENV}.dockerfile
restart: unless-stopped
extra_hosts:
- host.docker.internal:host-gateway
networks:
- iptv
dockerfile: docker/php/${IPTV_ENV}/dockerfile
volumes:
- /etc/localtime:/etc/localtime:ro
- ./docker/php/www.conf:/usr/local/etc/php-fpm.d/www.conf:ro
- ./docker/php/${IPTV_ENV}.php.ini:/usr/local/etc/php/conf.d/php.ini:ro
- ./docker/php/${IPTV_ENV}/www.conf:/usr/local/etc/php-fpm.d/www.conf:ro
- ./docker/php/${IPTV_ENV}/php.ini:/usr/local/etc/php/conf.d/php.ini:ro
- ./log/php:/var/log/php:rw
- ./src:/var/www:rw
- ./playlists.ini:/var/www/config/playlists.ini:ro
- ./svc-main:/var/www:rw
depends_on:
- keydb
nginx:
<<: *common-attributes
container_name: iptv-nginx
image: nginx:latest
restart: unless-stopped
extra_hosts:
- host.docker.internal:host-gateway
networks:
- iptv
volumes:
- /etc/localtime:/etc/localtime:ro
- ./docker/nginx/vhost.conf:/etc/nginx/conf.d/default.conf:ro
- ./log/nginx:/var/log/nginx:rw
- ./src:/var/www:ro
- ./svc-main:/var/www:ro
ports:
- '8080:80'
- "8080:80"
links:
- php
depends_on: