🔥 Nextcloud + Unit = Better speed 🔥
- Instead of the standard Apache, the new performance Nginx Unit is used
- Postgresql is used instead of SQLite / MySQL
- Redis based caching is used (APCu is not used for ease of support).
- alpine versions of postgres and redis containers are used. Less weight - more speed
- Use current version of php with OPCache enabled
With a regular docker container all-in-one on my server, the load took about 2-3sec. With the new configuration it takes about 1s to boot up
- Xeon 2640 v4 (10 core, 20 threads)
- 16 GB ECC RAM
- 256 SSD NVME (Samsung 970 EVO)
- 1GB Ethernet
- Debian 12
To run it, you need to download the archive with the latest version from the official website https://download.nextcloud.com/server/releases/. After downloading, put the files of this repository in one folder.
- Docker
- Cron (on host)
- docker-compose up -d
- In the cron entry on your host machine, you need to add the entry
*/5 * * * * * * docker exec -u $(id -u unit) nextcloud_unit_1 php cron.phpunit - owner of config/config.php file
- docker-compose.yml
- unit
- config.json
- Dockerfile
- pph.ini
- nextcloud
- public.php
- composer.json
- config
- updated
- ...
- In config/config.php enable logging of critical errors only. This way, Nextcloud will make fewer log entries
- Disable unnecessary standard applications and plugins