When cron.php takes too much time on wp docker run the following command to clear files:
docker exec -u www-data <your-wp-container-name-here> php occ files:cleanup
docker exec -u www-data
<your-wp-container-name-here>
php occ files:scan-app-data
This should make the next cron.php job faster.