diff --git a/docker-compose.yml b/docker-compose.yml index 1b6db08..f975ec2 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -23,7 +23,10 @@ services: php-fpm-nextcloud: container_name: php-fpm-nextcloud - build: ./php-fpm + build: + context: ./php-fpm + tags: + - localhost/php-fpm-nextcloud:latest volumes: - ${NEXTCLOUD_DIR}:/var/www/html - ${DATA_DIR}:/data @@ -54,6 +57,25 @@ services: networks: - nextcloud + cron-nextcloud: + container_name: cron-nextcloud + image: localhost/php-fpm-nextcloud:latest + restart: unless-stopped + command: + - bash + - -c + - "'while true; do php --define apc.enable_cli=1 /var/www/html/cron.php && sleep 300; done'" + networks: + - nextcloud + user: www-data + volumes: + - ${NEXTCLOUD_DIR}:/var/www/html + - ${DATA_DIR}:/data + depends_on: + - php-fpm-nextcloud + - redis-nextcloud + - mariadb-nextcloud + networks: nextcloud: driver: bridge