It is not as convenient as the one-liner to install a snap, however, it will work and probably only take you an hour or two (if its your first time and or unexperienced with getting a LAMP stack). I’d consider this more worth it for your time budget instead of hours of troublehhsooting.
To be fair, running your own Server never is as “easy” as one might think in the first place
That said, does the Pi Support Docker? Might be a medium Solution between completely rolling your own and using a snap. I’ve been running the NC Docker Container on my QNAP NAS for some time and it’s been stable and not making any issues… With Docker-compose, the setup should basically also be a one-liner.