drupalphil
drupalphil

Reputation: 91

Drupal multisite with path-based, nested, subdirectories not loading beyond homepage

I am hosting several Drupal sites on an internal server, and I'm attempting to set up a Drupal multisite environment using path-based subdirectories instead of subdomains.

Current setup

My goal

Now, I'm setting up a new multisite under the path /hub and would like to configure subsites in directories under it:

The sites.php file is set up to accommodate:

Issue

With a RewriteBase /hub along with 2 symlinks for each subsite, I can access the /hub site correctly, and I can load the homepage for the subsites (/hub/site1 and /hub/site2), but any paths beyond the homepage on the subsites return a 404 error (from /hub).

Question

What is the correct way to configure Apache, symlinks, and/or .htaccess to support this setup and allow the subsites' paths to resolve correctly?

Here’s what I’ve tried so far

  1. Apache alias: I've created aliases for /hub, /hub/site1, and /hub/site2.
  2. Symlinks: I’ve created symlinks in the /web directory for /web/site1 -> /web
  3. .htaccess: I've attempted many variations of rewrite conditions here, but to no avail.

How can I make sure that subsite paths like /hub/site1/somepage are properly handled and do not return 404 errors from /hub?

Any help or guidance would be greatly appreciated!

Upvotes: 0

Views: 87

Answers (0)

Related Questions