compose project

This commit is contained in:
2025-10-29 21:22:20 +01:00
parent 36a794bbd8
commit ba7616e4fa
8 changed files with 143 additions and 5 deletions

55
compose.yaml Normal file
View File

@@ -0,0 +1,55 @@
version: "3.9"
services:
mariadb:
image: mariadb
container_name: helpdesk-db
env_file:
- .env
volumes:
- ./mariadb:/var/lib/mysql
- ./initdb:/docker-entrypoint-initdb.d
networks:
- internal
restart: unless-stopped
labels:
- com.centurylinklabs.watchtower.enable=true
nginx:
image: nginx:stable-alpine
container_name: helpdesk-nginx
depends_on:
- php
volumes:
- ./nginx/conf.d:/etc/nginx/conf.d
- ./src:/var/www/html
networks:
- internal
- traefik_proxy
labels:
- traefik.enable=true
- traefik.docker.network=traefik_public
- traefik.http.routers.helpdesk.rule=Host(`${DOMAIN}`)
- traefik.http.routers.helpdesk.entrypoints=websecure
- traefik.http.routers.helpdesk.tls=true
- traefik.http.routers.helpdesk.tls.certresolver=tls-resolver
- com.centurylinklabs.watchtower.enable=true
restart: unless-stopped
php:
build:
context: .
dockerfile: Dockerfile
container_name: helpdesk-php
env_file:
- .env
volumes:
- ./src:/var/www/html
networks:
- internal
restart: unless-stopped
networks:
internal:
traefik_proxy:
external: true