docker/nextcloud/compose.yaml

74 lines
1.4 KiB
YAML

---
services:
install_site:
build: install_site
environment:
- BASE_URL
- EMAIL
- UPLOAD_LIMIT
volumes:
- ./nginx.conf:/web/nextcloud.conf
- sites:/sites/
- certs:/etc/letsencrypt/
- certbotroot:/var/www/certbot/
- /var/run/docker.sock:/var/run/docker.sock
db:
image: docker.io/postgres:15
restart: unless-stopped
environment:
- POSTGRES_DB
- POSTGRES_USER
- POSTGRES_PASSWORD
volumes:
- db:/var/lib/postgresql/data/
redis:
image: docker.io/redis:latest
restart: unless-stopped
volumes:
- redis:/data/
nextcloud:
build: .
restart: unless-stopped
env_file:
- .env
environment:
- POSTGRES_HOST=db
- REDIS_HOST=redis
- TRUSTED_PROXIES=nextcloud
- OVERWRITEPROTOCOL=https
- PHP_UPLOAD_LIMIT=$UPLOAD_LIMIT
- APACHE_BODY_LIMIT=0
volumes:
- nextcloud:/var/www/html/
- apps:/var/www/html/custom_apps/
- config:/var/www/html/config/
- data:/var/www/html/data/
- $MEDIA_PATH:/media/
networks:
- nginx
- default
depends_on:
- db
- redis
volumes:
sites:
external: true
certs:
external: true
certbotroot:
external: true
db: {}
redis: {}
nextcloud: {}
apps: {}
config: {}
data: {}
networks:
nginx:
external: true