Commit a298dcbd authored by Branimir Juranić's avatar Branimir Juranić Committed by Ev Maslovskiy
Browse files

Issue #3312263: Email reroute feature

parent 7fd758bb
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]
 - Added Reroute email module with configs which includes configuration for environments.

## [3.1.1]
- Added tests for 'automatic blocking of the super-admin user' functionality
+8 −0
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@ Dependencies
------------

- [REQUIRED] [Configuration Split](https://www.drupal.org/project/config_split)
- [REQUIRED] [Rereoute email](https://www.drupal.org/project/reroute_email)
- [OPTIONAL] [Features](https://www.drupal.org/project/features)

Configuration
@@ -68,6 +69,13 @@ For start using splits:
    $config['config_split.config_split.production']['status'] = TRUE;
    ~~~

#### Reroute email

The Domino module includes configuration for environments.

By default Reroute email is disabled but installed.
For non production environments (`development`, `staging`) the Reroute email module should be enabled (at /admin/config/development/reroute_email) to ensure that emails won't ever reach the end users. As a fallback, If Reroute Email is not enabled for non-production environment, email sending will be disabled completely, not just for rerouting emails.

### Super-admin user

Domino module blocks super-admin user (id = 1) and changes their username and password for security reasons. It will deactivate the user on cron or on cache flush in case when super-admin was activated manually.
+2 −1
Original line number Diff line number Diff line
@@ -32,6 +32,7 @@
  ],
  "require": {
    "drupal/core": "^9 || ^10",
    "drupal/config_split": "^2"
    "drupal/config_split": "^2",
    "drupal/reroute_email": "^2.1"
  }
}
+1 −0
Original line number Diff line number Diff line
@@ -5,3 +5,4 @@ package: Domino
core_version_requirement: ^9 || ^10
dependencies:
  - config_split:config_split
  - reroute_email:reroute_email
+12 −0
Original line number Diff line number Diff line
@@ -11,3 +11,15 @@
function domino_install() {
  domino_cache_flush();
}

/**
 * Installs Remote email module if not already installed.
 *
 * @see https://www.drupal.org/project/domino/issues/3312263
 */
function domino_update_8801() {
  $moduleHandler = \Drupal::service('module_installer');
  if (!$moduleHandler->moduleExists('reroute_email')) {
    $moduleHandler->install(['reroute_email']);
  }
}
Loading