502 Bad Gateway nginx for a drupal sub-directory site install

by Lloyd_07   Last Updated August 14, 2019 11:07 AM

I have a default drupal 8 site install and a sub directory site install. The second Drupal site was an after thought and had to be hosted on the default site url in a sub folder. both sites share the same database with the second site having a prefix for its tables.

The issue i am experiencing with the second site, the landing page works perfectly but any other page gives an issue, oddly enough when i view on incognito the other pages work but when i refresh i get the 502 Bad Gateway error.

folder structure is as follows

htdocs
 - core
 - libraries
 - modules
 - node_modules
 - profiles
 - sites
 - themes (custom default theme here)
 - vendor
 - site2 (where i installed the second site with its own custom theme)
 - default drupal files (index.php, .htaccess ....)

I didn't change anything in both .htaccess files, i also tried in site2 .htaccess uncommented and updated the RewriteBase /site2 but still get the 502.

If someone could point me to the right direction regarding this issue, i have googled and tried numerous changes to the .htaccess files.



Related Questions


Drupal multisite with sub-directory with nginx

Updated July 01, 2019 12:07 PM




Multi-site bulk module activation

Updated August 09, 2019 12:07 PM