When adding a secondary domain, example: the staging url to a live website URL, the nginx config has try_files $uri $uri/ =404; by default. This breaks all secondary URLS. Example Fix: if a wordpress install was detected, this should be set to try_files $uri $uri/ /index.php?$args;
Also, if manually updating the nginx config to try_files $uri $uri/ /index.php?$args; then this gets overwritten if you toggle the fastcgi button on/off on the latest version of the panel. Nginx changes don't persist.
More ways to test the bug:
Add new a new domain, and set it as primary. Delete old Primary domain.
All subpages are will now be 404.
Also, when re adding old primary domain this also results in 404.