1

I have two sites running from separate installations. I would like to move them to a multisite configuration. I am currently developing in a localhost environment.

I am starting by moving the first site into a multisite config within its own installation. I have given it its own unique folder in the sites directory, set up the sites.php file and given the site its own settings.php in its directory. When I navigate to the location specified in the sites.php configuration I get a not found error, and when I go to the drupal install directory, Drupal would like to do a fresh install.

Do I need to set up a .conf file in the sites-enabled folder of apache2?

Any help is greatly appreciated.

  • I may add that if you are not totally comfortable configuring Apache web server, then multisite may not be a good fit for you. But if you are willing to learn, you can make it work. It's a good way to learn ;-) – cilefen Jun 21 '16 at 0:43
2

Yes. Configure an apache virtual host for each site. They look something like this:

<VirtualHost *:80>
    DocumentRoot "/path/to/drupal/install"
    ServerName mysite.example.com
</VirtualHost>

<VirtualHost *:80>
    DocumentRoot "/path/to/drupal/install"
    ServerName myothersite.example.com
</VirtualHost>

Every virtual host in the multisite must be configured with the same DocumentRoot. The ServerName directive should match what you have used as the respective site's key in sites.php. Note that in this case *:80 signifies this virtual host listens on every IP of this server.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.