# Use the official Nextcloud image as the base image FROM nextcloud:latest # Install additional PHP modules if required (uncomment and add more if needed) RUN apt-get update && apt-get install -y php7.4-gd php7.4-ldap php7.4-redis # Environment variables for Nextcloud configuration (modify as needed) ENV MYSQL_DATABASE=nextcloud \ MYSQL_USER=b \ MYSQL_PASSWORD=b \ MYSQL_HOST=mariadb \ NEXTCLOUD_PORT=7860 # Expose the port Nextcloud will run on (default is 80) EXPOSE 7860 # NEXTCLOUD_PORT=7654 # Add a volume for storing Nextcloud data VOLUME /var/www/html # Start Nextcloud CMD ["apache2-foreground"]