2022-08-25 22:22:11 +02:00
|
|
|
version: '3.3'
|
|
|
|
services:
|
|
|
|
######## Datenbank ########
|
|
|
|
nextcloud-db:
|
2023-03-24 14:19:43 +01:00
|
|
|
image: mariadb:10
|
2022-08-25 22:22:11 +02:00
|
|
|
container_name: nextcloud-db
|
|
|
|
command: --transaction-isolation=READ-COMMITTED --log-bin=ROW --innodb_read_only_compressed=OFF
|
|
|
|
restart: unless-stopped
|
|
|
|
volumes:
|
|
|
|
- /etc/localtime:/etc/localtime:ro
|
|
|
|
- /etc/timezone:/etc/timezone:ro
|
|
|
|
- db:/var/lib/mysql
|
|
|
|
environment:
|
2023-04-06 19:53:27 +02:00
|
|
|
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
|
|
|
|
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
|
|
|
|
MYSQL_DATABASE: nextcloud
|
|
|
|
MYSQL_USER: nextcloud
|
|
|
|
MYSQL_INITDB_SKIP_TZINFO: 1
|
2022-08-25 22:22:11 +02:00
|
|
|
networks:
|
|
|
|
- intern
|
|
|
|
labels:
|
2023-04-20 14:50:33 +02:00
|
|
|
com.centurylinklabs.watchtower.enable: true
|
2023-03-21 19:00:37 +01:00
|
|
|
|
2022-08-25 22:22:11 +02:00
|
|
|
######## Redis ########
|
|
|
|
nextcloud-redis:
|
2023-03-24 14:19:43 +01:00
|
|
|
image: redis:7-alpine
|
2022-08-25 22:22:11 +02:00
|
|
|
container_name: nextcloud-redis
|
|
|
|
hostname: nextcloud-redis
|
|
|
|
networks:
|
|
|
|
- intern
|
|
|
|
restart: unless-stopped
|
|
|
|
command: redis-server --requirepass ${REDIS_HOST_PASSWORD}
|
|
|
|
labels:
|
2023-04-20 14:50:33 +02:00
|
|
|
com.centurylinklabs.watchtower.enable: true
|
2023-03-21 19:00:37 +01:00
|
|
|
|
2022-08-25 22:22:11 +02:00
|
|
|
######## cron ########
|
2023-04-20 21:10:10 +02:00
|
|
|
nextcloud-cron:
|
2022-08-25 22:22:11 +02:00
|
|
|
container_name: nextcloud-cron
|
2023-03-24 14:19:43 +01:00
|
|
|
image: rcdailey/nextcloud-cronjob:latest
|
2022-08-25 22:22:11 +02:00
|
|
|
restart: unless-stopped
|
|
|
|
network_mode: none
|
|
|
|
depends_on:
|
|
|
|
- nextcloud-app
|
|
|
|
volumes:
|
|
|
|
- /var/run/docker.sock:/var/run/docker.sock:ro
|
|
|
|
- /etc/localtime:/etc/localtime:ro
|
|
|
|
environment:
|
2023-04-06 19:53:27 +02:00
|
|
|
NEXTCLOUD_CONTAINER_NAME: nextcloud-app
|
|
|
|
NEXTCLOUD_CRON_MINUTE_INTERVAL: 1
|
2023-03-21 19:00:37 +01:00
|
|
|
labels:
|
2023-04-20 14:50:33 +02:00
|
|
|
com.centurylinklabs.watchtower.enable: true
|
2023-03-21 19:00:37 +01:00
|
|
|
|
2022-08-25 22:22:11 +02:00
|
|
|
######## Nextcloud ########
|
|
|
|
nextcloud-app:
|
|
|
|
image: nextcloud:${NC_MAJOR_VERSION}
|
|
|
|
container_name: nextcloud-app
|
|
|
|
restart: unless-stopped
|
|
|
|
depends_on:
|
|
|
|
- nextcloud-db
|
|
|
|
- nextcloud-redis
|
|
|
|
environment:
|
|
|
|
REDIS_HOST: nextcloud-redis
|
|
|
|
REDIS_HOST_PASSWORD: ${REDIS_HOST_PASSWORD}
|
|
|
|
MYSQL_DATABASE: nextcloud
|
|
|
|
MYSQL_USER: nextcloud
|
|
|
|
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
|
|
|
|
MYSQL_HOST: nextcloud-db
|
|
|
|
NEXTCLOUD_TRUSTED_DOMAINS: "nextcloud.mgrote.net"
|
|
|
|
SMTP_HOST: smtp.strato.de
|
|
|
|
SMTP_SECURE: tls
|
|
|
|
SMTP_PORT: 587
|
|
|
|
SMTP_AUTHTYPE: LOGIN
|
|
|
|
SMTP_NAME: info@mgrote.net
|
|
|
|
SMTP_PASSWORD: ${SMTP_PASSWORD}
|
|
|
|
MAIL_FROM_ADDRESS: info@mgrote.net
|
|
|
|
PHP_MEMORY_LIMIT: 1024M
|
|
|
|
PHP_UPLOAD_LIMIT: 10G
|
|
|
|
APACHE_DISABLE_REWRITE_IP: 1
|
2022-11-04 20:58:37 +01:00
|
|
|
TRUSTED_PROXIES: "192.168.2.43" # docker10.grote.lan/traefik
|
2022-08-25 22:22:11 +02:00
|
|
|
volumes:
|
|
|
|
- app:/var/www/html
|
|
|
|
- data:/var/www/html/data
|
|
|
|
networks:
|
|
|
|
- intern
|
|
|
|
# ports:
|
|
|
|
# - 80:80
|
|
|
|
networks:
|
|
|
|
- intern
|
|
|
|
- traefik
|
|
|
|
labels:
|
2023-04-20 14:50:33 +02:00
|
|
|
com.centurylinklabs.watchtower.enable: true
|
|
|
|
com.centurylinklabs.watchtower.depends-on: nextcloud-redis,nextcloud-db
|
2023-03-21 19:00:37 +01:00
|
|
|
|
2023-04-20 14:50:33 +02:00
|
|
|
traefik.http.routers.nextcloud.rule: Host(`nextcloud.mgrote.net`)
|
|
|
|
traefik.enable: true
|
|
|
|
traefik.http.routers.nextcloud.tls: true
|
|
|
|
traefik.http.routers.nextcloud.tls.certresolver: resolver_letsencrypt
|
|
|
|
traefik.http.routers.nextcloud.entrypoints: entry_https
|
|
|
|
traefik.http.services.nextcloud.loadbalancer.server.port: 80
|
2022-08-25 22:22:11 +02:00
|
|
|
|
2023-04-20 14:50:33 +02:00
|
|
|
traefik.http.middlewares.nextcloud-webdav.replacepathregex.regex: "^/.well-known/ca(l|rd)dav"
|
|
|
|
traefik.http.middlewares.nextcloud-webdav.replacepathregex.replacement: "/remote.php/dav/"
|
2022-08-25 22:22:11 +02:00
|
|
|
|
2023-04-20 14:50:33 +02:00
|
|
|
traefik.http.middlewares.nextcloud-hsts.headers.stsincludesubdomains: false
|
|
|
|
traefik.http.middlewares.nextcloud-hsts.headers.stspreload: true
|
|
|
|
traefik.http.middlewares.nextcloud-hsts.headers.stsseconds: 15552001
|
|
|
|
traefik.http.middlewares.nextcloud-hsts.headers.isdevelopment: false
|
2022-08-25 22:22:11 +02:00
|
|
|
|
2023-04-21 11:53:59 +02:00
|
|
|
traefik.http.routers.nextcloud.middlewares: nextcloud-hsts,nextcloud-webdav
|
2022-08-25 22:22:11 +02:00
|
|
|
|
|
|
|
######## Networks ########
|
|
|
|
networks:
|
|
|
|
intern:
|
|
|
|
driver: bridge
|
|
|
|
traefik:
|
|
|
|
external: true
|
|
|
|
######## Volumes ########
|
|
|
|
volumes:
|
|
|
|
db:
|
|
|
|
app:
|
|
|
|
data:
|
|
|
|
|
|
|
|
######## Doku ########
|
|
|
|
# Telefonregion
|
|
|
|
# docker exec --user www-data nextcloud-app php occ config:system:set default_phone_region --value="DE"
|