version: '3' services: nextcloud-app: build: ./docker/app #image: pgollor/nextcloud:app-dev-latest restart: always cpus: 1.5 depends_on: - nextcloud-database - nextcloud-redis env_file: - db.env - cloud.env environment: - MYSQL_HOST=nextcloud-database - MYSQL_DATABASE=cloud - MYSQL_USER=cloud - NEXTCLOUD_ADMIN_USER=${NEXTCLOUD_ADMIN_USER} - NEXTCLOUD_DATA_DIR=/srv/data - REDIS_HOST=nextcloudnextcloud-redis - TZ=${TZ} tmpfs: - /tmp volumes: - ./data/app:/var/www/html - ./data/data:/srv/data - ./data/conf/net.conf:/etc/sane.d/net.conf:ro nextcloud-web: #build: ./docker/web image: pgollor/nextcloud:web-latest restart: always logging: driver: json-file ports: - "${NEXTCLOUD_WEB_BIND:-127.0.0.1}:${NEXTCLOUD_WEB_PORT:-8080}:80" volumes: - ./data/app:/var/www/html:ro links: - "nextcloud-app:app" depends_on: - nextcloud-app nextcloud-database: image: mariadb restart: always command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW environment: - MYSQL_DATABASE=cloud - MYSQL_USER=cloud env_file: - db.env volumes: - nextcloud-db-vol-1:/var/lib/mysql/ - ./data/conf/mysql:/etc/mysql/conf.d/:ro tmpfs: - /tmp nextcloud-redis: image: redis:alpine restart: always nextcloud-cron: image: nextcloud:fpm-alpine restart: always volumes: - ./data/app:/var/www/html - ./data/data:/srv/data logging: driver: json-file entrypoint: /cron.sh #entrypoint: | # bash -c 'bash -s <<EOF # trap "break;exit" SIGHUP SIGINT SIGTERM # # while [ ! -f /var/www/html/config/config.php ]; do # sleep 1 # done # # while true; do # php -f /var/www/html/cron.php # sleep 15m # done # EOF' depends_on: - nextcloud-database - nextcloud-redis volumes: nextcloud-db-vol-1: