Drupal


Error

You must log in or register to view this page

Drupal is a Content Management System

Architecture

Drupal can run under any webserver.  Apache, Nginx and IIS are the most common.  Drupal version 11 and later does not support IIS.  The product also communicates with a database.

Software pattern summary

The following table gives an overview of the pattern characteristics:

Product componentOS typeVersioningPattern depth
DrupalUNIX, WindowsActuive, FileInstance based

Platforms supported by the pattern

The pattern discovers Drupal deployments on the UNIX and Windows systems.

Identification

Pattern Trigger

The pattern triggers on a SoftwareInstance that matches one of the following criteria

  • Type equals “Apache Webserver” and config_file attribute is populated
  • Type ends with “Apache Web Server” and config_file attribute is populated
  • Type equals “Nginx Webserver” and configuration_file attribute is populated
  • Type equals “Microsoft IIS Webserver”

False Positive Checking

The pattern will only create a SoftwareInstance if one of the following conditions is true

  • There is a child SoftwareComponent whose instance name contains ‘drupal’
  • Versioning is successful (see below)
  • For Apache installations only: the DocumentRoot ends with drupal (the DocumentRoot is found in the config_file as reported on the SoftwareInstance)
  • For Nginx installations only: root ends in drupal. The root is obtained from one of the Nginx configuration files
  • For Nginx installations only: drupal.conf is one of the include directories as reported in one of the Nginx configuration files
  • For IIS only: the child of the IIS trigger process contains argument -ap drupal
  • For IIS only: the child of the IIS trigger process contains argument -h drupal.config

Simple identification mappings

The pattern does not create Simple Identification Mappings

Versioning

Version information for the product is collected by using the active versioning and file versioning methods.

Install Root

The pattern gets the installation root by one of the following methods:

  • For Apache Based Webservers it is the DocumentRoot as reported in the config_file described on the SI
  • For Nginx Webserver it is the root as reported in one of the Nginx configuration files
  • For IIS if the path to the drupal.config file.  The pattern obtains this from the -h option of the IIS child process.

Active Versioning

The pattern runs command <install root>/drush status.  This will give the value of ‘drupal version’

File Versioning

The pattern attempts to find version from one of the following two files

FileMethod to read fileText to search for in file
<install_root>/web/core/lib/Drupal.phpRead file using Discoveryconst VERSION = <version>
<install root>/docs/CHANGELOG.txtParse file with findstr or grepDrupal <version>

Software Model

The pattern creates an instance based SoftwareInstance with the key based on type and the key of the trigger SoftwareInstance

The pattern creates a Client Server relationship to the triggering SoftwareInstance or the drupal SoftwareComponent that is its child.  The triggering web server is the client.

The pattern finds the linked database from the following attributes given by the the drush status command.

  • Db hostname
  • Db driver (could be mysql, mariadb, mongodb, mssql or postgresql)
  • Db port
  • Db name

The pattern creates a client server relationship to the database.  The database is the server

So a typical installation might look like this

1757948040764-581.png

Subject matter expertise

Inputs from subject matter experts are welcome on any other potential approaches not discussed in this topic.

Testing

The pattern has been tested against the available customer data.

Open issues

There are no known open issues with this pattern.

 

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

BMC Discovery content reference