commit ad8f074f8793edaa0921725d28be9b6baa2d8a07 Author: root Date: Sun Dec 14 18:27:38 2025 +0100 initial commit diff --git a/.docker-compose.yml.swp b/.docker-compose.yml.swp new file mode 100644 index 0000000..d1596b3 Binary files /dev/null and b/.docker-compose.yml.swp differ diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..39da03f --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +.env +data/ +db/ diff --git a/db-config/my.cnf b/db-config/my.cnf new file mode 100644 index 0000000..a755c3c --- /dev/null +++ b/db-config/my.cnf @@ -0,0 +1,7 @@ +[mysqld] +innodb_buffer_pool_size = 1G +innodb_log_file_size = 256M +innodb_flush_log_at_trx_commit = 2 +innodb_flush_method = O_DIRECT +query_cache_size = 0 +query_cache_type = 0 diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..6bc7fe0 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,68 @@ +services: + nextcloud: + image: nextcloud:latest + container_name: nextcloud + restart: unless-stopped + ports: + - "127.0.0.1:8888:80" + volumes: + - ./data:/var/www/html + environment: + - MYSQL_HOST=db + - MYSQL_DATABASE=nextcloud + - MYSQL_USER=${MYSQL_USER} + - MYSQL_PASSWORD=${MYSQL_PASSWORD} + + - NEXTCLOUD_TRUSTED_DOMAINS=cloud.agence66.fr + - OVERWRITEPROTOCOL=https + - OVERWRITEHOST=cloud.agence66.fr + + - REDIS_HOST=${REDIS_HOST} + - REDIS_HOST_PASSWORD=${REDIS_HOST_PASSWORD} + + - PHP_UPLOAD_MAX_FILESIZE=10G + - PHP_MEMORY_LIMIT=2048M + - PHP_MAX_EXECUTION_TIME=360 + - PHP_MAX_INPUT_TIME=360 + + - APACHE_BODY_LIMIT=10737418240 + depends_on: + - db + networks: + - nextcloud-net + - traefik-net + redis: + image: redis:alpine + restart: unless-stopped + networks: + - nextcloud-net + command: redis-server --requirepass ${REDIS_HOST_PASSWORD} + nextcloud-cron: + image: nextcloud:latest + restart: always + volumes_from: + - nextcloud + entrypoint: /cron.sh + depends_on: + - nextcloud + - db + networks: + - nextcloud-net + db: + image: mariadb:10.11 + restart: unless-stopped + volumes: + - ./db:/var/lib/mysql + - ./db-config/my.cnf:/etc/mysql/conf.d/custom.cnf:ro + environment: + - MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_USER} + - MYSQL_DATABASE=nextcloud + - MYSQL_USER=${MYSQL_USER} + - MYSQL_PASSWORD=${MYSQL_PASSWORD} + networks: + - nextcloud-net +networks: + nextcloud-net: + driver: bridge + traefik-net: + external: true