Drupal stands out among the best solutions for business. Yet how to make it work for larger companies that need to manage many complex sites simultaneously? The answer is Drupal multisite. Learn how to use it by reading this article.
What is Drupal multisite?
At its shortest, a Drupal multisite (also referred to as a Drupal multi-installation) consists of multiple sites combined in a single Drupal installation. Each site is located in a different folder of the platform's system directory and has separate settings.php and database files associated with it. Of course, the sites have different web addresses and may have other content - all depends on your needs.
In Drupal multisite, sites are sharing:
- the same version of Drupal core,
- the available modules,
- the available themes,
- the base code.
At the same time, the sites do not share:
- the domains,
- the URLs,
- the databases,
- the enabled modules,
- the enabled themes,
- the configurations,
- the user profiles,
- the content,
- the files.
With such structure in place, it is possible to create a set of pages that are conveniently created, managed, deployed and updated from a single location, yet vary in content and design.
Advantages of using Drupal multisite
The fundamental reason for using Drupal multisite is to save time when managing many sites that use the same version of Drupal core. That is because each time a new Drupal update is released, it only needs to be carried out on a single code base instead of doing it for each site separately.
The benefits of such an installation are apparent not only at the site management stage but also at the initial site creation stage. That is because, in the case of Drupal multisite, it is sufficient to design a main basic theme. Then, the theme's inheritance mechanism will allow you to pass this foundation on to subsequent projects so that you can quickly move on to working on unique features for them.
Drupal multi-installation also offers long-term benefits. It helps to reduce and pay off the future technical debt that occurs when companies make compromises to achieve their plans. Such decisions are often unavoidable in business. The problem arises when technical debt becomes too large. As a result, it becomes increasingly difficult to maintain sites, and making major edits (e.g., changing a theme) is too complicated because of legacy code, which in addition, is different for each site.
Websites running on Drupal multisite not only have less of a technical debt problem, but are also characterized by better quality than many websites put up separately. That is because this solution saves resources that would otherwise have to be used, for example, on hiring agency to create another project. Developers themselves, when laying the foundations for a multisite project, will also make more of an effort to prepare flexible and sustainable solutions when they realize that putting in the necessary effort in this area will pay off in the future.
Check out the Drupal multisite implementation details
on WSB Universities exampleRead case study
Disadvantages of Drupal multisite
Drupal multisite is not the best option if the sites you intend to serve will differ significantly in functionality and design. Of course, such an endeavour is possible, but you will unnecessarily spend too much time struggling with the platform itself rather than realising its true potential.
Another issue to keep in mind is security. If any problems in this respect arise on one site, they will probably affect the rest of the related sites as well. Similarly, the consequences of errors made during installation or upgrades will have wide-ranging implications.
Drupal multisite - types of installation
There are several ways to design a Drupal multisite architecture. We outline each of these in brief below.
Classical multisite approach
This approach looks no different from the one discussed earlier - with separate configurations, databases, etc. However, the basic code base is common. On the other hand, the Features module allows the same functionality to be used by importing configurations. With Configuration Split, on the other hand, it is possible to decide which configurations should be shared and which should be eliminated.
This model is similar to the one described above. The difference, however, is that all pages share a common database. This is where the Domain module comes in handy, as it allows numerous pages to be managed, and content to be categorized and put in the right places. This design makes updating individual pages less of a hassle. The disadvantage, however, is that adding separate functionalities to individual sites is much more difficult. Therefore it is a solution suitable for similar sites.
Drupal multi-installation - summary
Drupal multisite is a great solution that will work well for businesses running multiple websites simultaneously. By investing in a multisite, you can significantly reduce the time spend managing your sites and, in turn, save a lot of money. So consider the benefits of this solution when setting up multiple sites for your business.