KazV2/dockers/gitea/docker-compose.yml

53 lines
1.1 KiB
YAML

services:
web:
image: gitea/gitea
container_name: ${gitServName}
restart: ${restartPolicy}
ports:
# - 8088:3000/tcp
- 2202:22/tcp
networks:
- giteaNet
- postfixNet
external_links:
- ${smtpServName}:${smtpHost}
volumes:
- gitData:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
depends_on:
- db
environment:
- USER_UID=1000
- USER_GID=1000
labels:
- "traefik.enable=true"
- "traefik.http.routers.${gitServName}.rule=Host(`${gitHost}.${domain}`)"
- "traefik.http.services.${gitServName}.loadbalancer.server.port=3000"
- "traefik.docker.network=giteaNet"
db:
image: mariadb:10.5
container_name: ${gitDBName}
restart: ${restartPolicy}
env_file:
- ../../secret/env-${gitDBName}
volumes:
- gitDB:/var/lib/mysql
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
networks:
- giteaNet
volumes:
gitDB:
gitData:
networks:
giteaNet:
external: true
name: giteaNet
postfixNet:
external: true
name: postfixNet