I replied in another thread to this, but you should consider having the nextcloud on another server. Depending on your server performance, and what you are doing on it, it would be faster to just host it on another machine. I would recommend freenas, BSD jails are great for this stuff and you wouldn't tie down your internet/firewall performance when stressing your gateway. If you can budget it build a freenas machine and all these issues are solved. It wouldnt be to likely nethserver will see nginx for a very long time, as it would require almost a complete rebase on many core components.
Edit: Im an idiot, I meant BSD not BAD....I was tired when I wrote!