Review main Work in progress Orphaned

91877[FEATURE] Add console command to execute silent migrations

Lina Wolf CR -2 V 0 Hard +328 −0 updated 01/25/26, 09:10

Commit message

A new EXT:core command `settings:migrate` allows executing silent
configuration migrations from the CLI. The command creates a temporary
backup of the system configuration file, restores it on failure, and
in verbose mode shows a unified diff of configuration changes.

For security reasons, a new internal `ConfigurationBlindingService` was
introduced. It centralizes and reuses the blinding logic from the
configuration module and ensures all diff output is based on
blinded configuration data, preventing exposure of sensitive
values. The service also supports blinding additional options
by via `ModifyBlindedConfigurationOptionsEvent`.

The event `TYPO3\CMS\Lowlevel\Event\ModifyBlindedConfigurationOptionsEvent`
has been moved to `\TYPO3\CMS\Core\Configuration\Event\ModifyBlindedConfigurationOptionsEvent`.

Test this change

Run a command in your clone of the TYPO3 Core. Then try what the change does and vote on Verified in Gerrit. How to review a patch

Check out patch set 17
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/77/91877/17 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/77/91877/17 && git cherry-pick FETCH_HEAD

Review

  • Code review CR -2 Blocked
    • Stefan Bürk -2
  • Verified V 0 Needs a vote
    • core-ci +1 CI

Relation chain 2

  1. 91877 [FEATURE] Add console command to execute silent migrations This change

  2. main 92494[TASK] Create service to blind configuration options in a central place This change is based on it Abandoned Lina Wolf CR 0 V -1 Hard +377 −127

    The chain has patch set 1 of 3, the changes above it need a rebase.

Issues 1

Files 3

Review log 3552

Show 1927 earlier messages
  1. Lina Wolf uploaded patch set 1 11/25/25, 12:51

  2. Lina Wolf marked it work in progress 11/25/25, 12:51

  3. Mathias Brodala commented on patch set 1 11/25/25, 12:55

    UpgradeSilentMigrationsCommand.php:50

    IMO this should be part of "upgrade:run" instead to avoid introducing a separate command which must be integrated everywhere. (Of course in the long term a general "migrate" command would make sense which could cover this and more.)
  4. core-ci voted on patch set 1 V -1 11/25/25, 13:00 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/90948

  5. Lina Wolf commented on patch set 1 11/25/25, 14:17

    UpgradeSilentMigrationsCommand.php:50 Reply

    This command can be run without database access and therefore in a pipeline that has none. It can be used to check the integrity of the settings.php
  6. Mathias Brodala commented on patch set 1 11/25/25, 14:24

    UpgradeSilentMigrationsCommand.php:50 Reply

    Hm, makes sense. Still wonder if upgrade:run could be adjusted accordingly. If kept, then "settings:migrate" or "configuration:migrate" would be clearer.
  7. Lina Wolf commented on patch set 1 11/25/25, 14:29

    UpgradeSilentMigrationsCommand.php:50 Reply

    settings:migrate might be a good name. This is still very much work in progress however and just some first thoughts. Not anywhere ready for review ;) upgrade:run needs a database as most upgrade wizards upgrade database rows.
  8. Lina Wolf uploaded patch set 2 V -1 11/25/25, 14:49

  9. core-ci voted on patch set 2 V -1 11/25/25, 14:58 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/90958

  10. Lina Wolf commented on patch set 2 11/25/25, 18:27

    UpgradeSilentMigrationsCommand.php:50 Reply

    Done
  11. Lina Wolf uploaded patch set 3 V -1 12/04/25, 13:49

  12. Lina Wolf uploaded patch set 4 12/04/25, 13:50

  13. Lina Wolf uploaded patch set 5 12/04/25, 13:52

  14. core-ci voted on patch set 3 V -1 12/04/25, 14:05 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91590

  15. core-ci voted on patch set 4 V -1 12/04/25, 14:06 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91591

  16. core-ci voted on patch set 5 V -1 12/04/25, 14:07 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91592

  17. Lina Wolf uploaded patch set 6 V -1 12/04/25, 16:39

  18. Lina Wolf marked it ready for review 12/04/25, 16:44

  19. core-ci voted on patch set 6 V -1 12/04/25, 16:48 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91594

  20. Lina Wolf uploaded patch set 7 V -1 12/04/25, 17:23

  21. core-ci voted on patch set 7 V +1 12/04/25, 17:30 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91598

  22. Simon Schaufelberger commented on patch set 7 12/05/25, 11:08

    SettingsMigrationCommand.php:64

    ```suggestion 'Maximal number of tries.', ```

    SettingsMigrationCommand.php:148

    this looks very much like AI code. please remove the numbering

    ConfigurationBlindingService.php:137

    move the is_array check into new line

    ConfigurationBlindingService.php:142

    make it one line
  23. Mathias Brodala commented on patch set 7 12/05/25, 11:20

    ConfigurationBlindingService.php:137 Reply

    Or even better: if (isset($configuration['DB']['Connections']['Default'])) No need to check each array key, isset() already does that. The check for array is not necessary IMO.
  24. Lina Wolf commented on patch set 8 V +1 12/05/25, 11:25

    Published edit on patch set 7.
  25. Lina Wolf commented on patch set 8 12/05/25, 11:25

    SettingsMigrationCommand.php:64 Reply

    Fix applied.
  26. core-ci voted on patch set 8 V +1 12/05/25, 11:32 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91644

  27. Lina Wolf uploaded patch set 9 V +1 12/05/25, 11:35

  1. Lina Wolf commented on patch set 9 12/05/25, 11:37

    SettingsMigrationCommand.php:148 Reply

    I am very much able to use numbering myself, but the comment has become superfluous by properly named method names.

    ConfigurationBlindingService.php:137 Reply

    Done

    ConfigurationBlindingService.php:142 Reply

    Done
  2. core-ci voted on patch set 9 V -1 12/05/25, 11:42 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91645

  3. Lina Wolf uploaded patch set 10 V -1 12/06/25, 08:27

  4. core-ci voted on patch set 10 V +1 12/06/25, 08:35 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/91722

  5. Garvin Hicking commented on patch set 10 12/12/25, 11:52

    duplicated paragraph
  6. Lina Wolf updated the commit message in patch set 11 V +1 12/13/25, 02:10

  7. Lina Wolf commented on patch set 11 12/13/25, 02:10

    Reply

    Done
  8. core-ci voted on patch set 11 V +1 12/13/25, 02:18 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/92171

  9. Lina Wolf rebased onto patch set 12 V +1 01/10/26, 06:08

  10. core-ci voted on patch set 12 V +1 01/10/26, 06:18 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/93188

  11. Simon Praetorius commented on patch set 12 CR -1 01/10/26, 19:16

    SettingsMigrationCommand.php:73

    This file must use `.bak.php` or similar as file extension. Otherwise we risk exposing credentials on systems where the webserver isn't properly configured to disallow access to var/transient/*.

    SettingsMigrationCommand.php:107

    The backup file must be deleted at the end.

    GlobalVariableProvider.php:49

    I would remove this comment.

    ConfigurationBlindingService.php:120

    I have the feeling that this service should be a pre-patch. There are two more usages of the event which remain in their original position. Also, the service is named generically, but includes special handling for DB connections, which is only relevant for TYPO3_CONF_VARS.
  12. Stefan Bürk commented on patch set 12 CR -2 01/10/26, 22:48

    Unresolved

    Will comment in detail later, but that change should not go in in that way. Short arguments: * Command should be provided by EXT:core and not EXT:lowlevel (optional). * The event should be moved to EXT:core (keeping the namespace) and deprecated, adding a new one in EXT:core with new namespace, dispatching both. Similar how I did/doing it for event(s) to move the language:update command: 91952: [WIP][TASK] Move command "language:update" to `EXT:core` | https://review.typo3.org/c/Packages/TYPO3.CMS/+/91952 * Like Simon mentioned, the new "service" should be use a more suiting name, and also be provided in EXT:core instead of EXT:lowlevel. The main benefit of the commit is to have it available in pipelines (CI/CD) and it makes no sense to have it provided by a optional extension and forcing people to install the extension, use the command, and uninstall it when not required in deployed environment. To be honest, I did not a real review yet - just had a quick look and wanted to state the main pain points. Decided to give it a -2 temporary to ensure that this get not merged into the optional extension and **not** as a general block a.k.a. `we don't do that`.
  13. Lina Wolf uploaded patch set 13 CR -1 V +1 01/24/26, 12:53

    Copied Votes: * Code-Review-2 (copy condition: "changekind:NO_CHANGE OR **is:MIN**")
  14. core-ci voted on patch set 13 V -1 01/24/26, 13:01 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/94254

  15. Lina Wolf uploaded patch set 14 V -1 01/24/26, 13:35

    Copied Votes: * Code-Review-2 (copy condition: "changekind:NO_CHANGE OR **is:MIN**")
  16. Lina Wolf commented on patch set 14 01/24/26, 13:36

    SettingsMigrationCommand.php:73 Reply

    Done

    SettingsMigrationCommand.php:107 Reply

    Done
  17. core-ci voted on patch set 14 V +1 01/24/26, 13:43 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/94255

  18. Lina Wolf uploaded patch set 15 V +1 01/24/26, 13:46

    Copied Votes: * Code-Review-2 (copy condition: "changekind:NO_CHANGE OR **is:MIN**")
  19. Lina Wolf uploaded patch set 16 01/24/26, 13:49

    Copied Votes: * Code-Review-2 (copy condition: "changekind:NO_CHANGE OR **is:MIN**")
  20. core-ci voted on patch set 15 V +1 01/24/26, 13:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/94256

  21. core-ci voted on patch set 16 V +1 01/24/26, 13:59 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/94257

  22. Lina Wolf rebased onto patch set 17 V +1 01/24/26, 14:23

    Copied Votes: * Code-Review-2 (copy condition: "changekind:NO_CHANGE OR **is:MIN**")
  23. Lina Wolf commented on patch set 17 01/24/26, 14:24

    GlobalVariableProvider.php:49 Reply

    Done

    ConfigurationBlindingService.php:120 Reply

  24. core-ci voted on patch set 17 V +1 01/24/26, 14:32 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/94260

  25. Lina Wolf marked it work in progress 01/25/26, 09:10