Files
srvdocker02_compose_files/compose_files/nextcloud.yml
mindesbunister d7c6bc8375 Phase 0: Performance Quick Wins
Implemented comprehensive performance optimizations across 7 services:

Redis Caching:
- Firefly III: Added Redis cache for sessions and application cache (84.6% hit rate)
- Gitea: Configured Redis for cache, sessions, and task queues
- Synapse: Enabled Redis cache for Matrix homeserver
- Nextcloud: Already had Redis, added tmpfs and proper container naming

Database Tuning:
- Zabbix: Added MySQL tuning (existing performance.cnf with 3GB buffer already optimal)
- Paperless: MariaDB tuning (256MB buffer, 64MB log, 50 connections)
- Trading Bot: PostgreSQL tuning (128MB shared_buffers, optimized work_mem)
- Firefly III: MariaDB optimization (512MB buffer, 128MB log, 100 connections)

Tmpfs Mounts (in-memory temporary storage):
- Nextcloud: 1GB /tmp, 512MB /var/tmp
- Paperless: 512MB /tmp, 256MB /var/tmp
- Jellyfin: 2GB /tmp, 1GB /var/tmp (for transcoding)

Container Naming:
- Nextcloud: Renamed from compose_files_* to nextcloud-redis, nextcloud-db, nextcloud-app

Documentation:
- Updated INFRASTRUCTURE_ROADMAP.md with Phase 0 section and completion tracking
- Created PERFORMANCE_IMPROVEMENTS_2025-11-12.md with detailed change log
- Created deploy-performance-improvements.sh automation script

All services verified healthy and running with improvements.
2025-11-13 10:18:10 +01:00

92 lines
2.3 KiB
YAML
Executable File

version: '3'
services:
redis:
image: redis:alpine
container_name: nextcloud-redis
restart: unless-stopped
volumes:
- redis_data:/data
networks:
nextcloud:
aliases:
- redis
db:
#logging:
#driver: loki
#options:
#loki-url: "http://localhost:3100/loki/api/v1/push"
image: mariadb:10.5
container_name: nextcloud-db
command: --innodb-buffer-pool-size=4G --innodb-log-file-size=512M --max-connections=200
volumes:
- /home/icke/mariadb-nextcloud/db:/var/lib/mysql
- /etc/localtime:/etc/localtime:ro
environment:
- MYSQL_ROOT_PASSWORD=eccmts42*
- MYSQL_PASSWORD=eccmts42*
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
restart: unless-stopped
networks:
nextcloud:
aliases:
- db
app:
#logging:
#driver: loki
#options:
#loki-url: "http://localhost:3100/loki/api/v1/push"
image: nextcloud_full:30
container_name: nextcloud-app
depends_on:
- db
- redis
ports:
- 8089:80
volumes:
- /home/icke/nextcloud:/var/www/html
- /home/icke/nextcloud/config:/var/www/html/config
- /home/icke/nextcloud/custom_apps:/var/www/html/custom_apps
- /mnt/nextcloud:/var/www/html/data
# - /var/lib/vz/images/101:/var/www/html/data
- /home/icke/nextcloud/themes:/var/www/html/themes
- /etc/localtime:/etc/localtime:ro
- /home/icke/nextcloud/php.ini:/usr/local/etc/php/conf.d/upload_size.ini
environment:
- VIRTUAL_HOST=nextcloud.egonetix.de
- UPLOAD_MAX_SIZE=20G
#- LOG_LEVEL=DEBUG
restart: unless-stopped
tmpfs:
- /tmp:size=1G
- /var/tmp:size=512M
networks:
nextcloud:
aliases:
- app
#collabora:
#logging:
# driver: loki
# options:
# loki-url: "http://localhost:3100/loki/api/v1/push"
#image: collabora/code
#container_name: collabora
#cap_add:
# - MKNOD
#ports:
# - 9980:9980
#environment:
# - domain=nextcloud.egonetix.de
# - aliasgroup1=https://nextcloud.egonetix.de
#restart: unless-stopped
volumes:
nextcloud:
db:
redis_data:
#collabora:
networks:
nextcloud:
driver: bridge
external: false