145 lines
3.9 KiB
YAML
145 lines
3.9 KiB
YAML
version: '3'
|
|
|
|
services:
|
|
|
|
app:
|
|
image: nextcloud
|
|
restart: always
|
|
networks:
|
|
- proxy
|
|
- nextcloud
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.nextcloud.rule=Host(`${HOSTNAME}`)"
|
|
- "traefik.http.routers.nextcloud.service=nextcloud"
|
|
- "traefik.http.routers.nextcloud.entrypoints=websecure"
|
|
- "traefik.http.services.nextcloud.loadbalancer.server.port=80"
|
|
- "traefik.http.routers.nextcloud.tls=true"
|
|
- "traefik.http.routers.nextcloud.tls.certresolver=letsencrypt"
|
|
- "traefik.http.services.nextcloud.loadbalancer.passhostheader=true"
|
|
- "traefik.http.routers.nextcloud.middlewares=compresstraefik"
|
|
- "traefik.http.middlewares.compresstraefik.compress=true"
|
|
volumes:
|
|
- ./data/nextcloud/www:/var/www/html
|
|
#- ./default-config/preview.config.php:/var/www/html/config/preview.config.php
|
|
depends_on:
|
|
#- clamav
|
|
- preview
|
|
- db
|
|
- redis
|
|
environment:
|
|
- POSTGRES_HOST=db
|
|
- REDIS_HOST=redis
|
|
- POSTGRES_DB=nextcloud
|
|
- POSTGRES_USER=${POSTGRES_USER}
|
|
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
|
- NEXTCLOUD_TRUSTED_DOMAINS=${HOSTNAME}
|
|
- OVERWRITEPROTOCOL=https
|
|
- TRUSTED_PROXIES=${NEXTCLOUD_TRUSTED_PROXIES}
|
|
- APACHE_DISABLE_REWRITE_IP=1
|
|
|
|
preview:
|
|
image: docker.io/nextcloud/aio-imaginary:latest
|
|
restart: always
|
|
networks:
|
|
- nextcloud
|
|
environment:
|
|
- PORT=9000
|
|
command: -concurrency 50 -enable-url-source
|
|
|
|
collabora-code:
|
|
image: collabora/code
|
|
container_name: collabora-code
|
|
cap_add:
|
|
- MKNOD
|
|
ports:
|
|
- 9980:9980
|
|
environment:
|
|
- "domain=cloud\\.dev\\.mertens\\.digital"
|
|
- username=admin
|
|
- "extra_params=--o:ssl.enable=false --o:ssl.termination=true"
|
|
- password=CREATE-A-SECURE-PASSWORD-HERE
|
|
restart: unless-stopped
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.collabora.entrypoints=websecure"
|
|
- "traefik.http.routers.collabora.rule=Host(`${COLLABORA_FQDN}`)"
|
|
- "traefik.http.routers.collabora.tls=true"
|
|
- "traefik.http.routers.collabora.tls.certresolver=letsencrypt"
|
|
- "traefik.http.services.collabora.loadbalancer.server.port=9980"
|
|
#- "traefik.http.services.collabora.loadbalancer.passhostheader=true"
|
|
networks:
|
|
- proxy
|
|
|
|
# clamav:
|
|
# image: "clamav/clamav:stable_base"
|
|
# container_name: "clamav"
|
|
# networks:
|
|
# - nextcloud
|
|
# volumes:
|
|
# - ./data/clamav/virus_db:/var/lib/clamav/ # Virus database
|
|
# restart: unless-stopped
|
|
|
|
# Does Not Work
|
|
#notify_push:
|
|
# image: icewind1991/notify_push
|
|
# restart: always
|
|
# networks:
|
|
# - nextcloud
|
|
# - caddy
|
|
# labels:
|
|
# caddy: ${HOSTNAME}
|
|
# caddy.handle_path: /push/*
|
|
# caddy.handle_path.0_reverse_proxy: "{{upstreams http 7867}}"
|
|
# depends_on:
|
|
# - db
|
|
# - redis
|
|
# - app
|
|
# volumes:
|
|
# - ./data/nextcloud/www:/var/www/html:ro
|
|
# - /etc/localtime:/etc/localtime:ro
|
|
# - /etc/timezone:/etc/timezone:ro
|
|
# environment:
|
|
# - PORT=7867
|
|
# - "NEXTCLOUD_URL=http://app" # don't go through the proxy to contact the nextcloud server
|
|
# entrypoint: ./notify_push --allow-self-signed --dump-config redis://:@redis --log-level debug /var/www/html/config/config.php
|
|
|
|
cron:
|
|
image: nextcloud
|
|
restart: always
|
|
volumes:
|
|
- ./data/nextcloud/www:/var/www/html
|
|
entrypoint: /cron.sh
|
|
depends_on:
|
|
- db
|
|
- redis
|
|
networks:
|
|
- nextcloud
|
|
|
|
|
|
db:
|
|
image: postgres:alpine
|
|
restart: always
|
|
networks:
|
|
- nextcloud
|
|
environment:
|
|
POSTGRES_DB: nextcloud
|
|
POSTGRES_USER: ${POSTGRES_USER}
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
volumes:
|
|
- ./data/db:/var/lib/postgresql/data
|
|
- /etc/localtime:/etc/localtime:ro
|
|
|
|
redis:
|
|
image: redis:alpine
|
|
restart: always
|
|
networks:
|
|
- nextcloud
|
|
|
|
|
|
networks:
|
|
nextcloud:
|
|
internal: true
|
|
proxy:
|
|
external: true
|