RFC Language Change PR-5.3-dev Pending

User tests: Successful: 0 Unsuccessful: 0

avatar alikon
alikon
21 Jan 2025

RFC Pull Request for Issue #44643 .

Summary of Changes

Add a new switch in the configuration.php to enable a "Safe Mode"
when "Safe Mode" is switched on it disables all non core plugin and take a "list"
when "Safe Mode" is on it keep track of non core plugin events and update the "list"
when "Safe Mode" is switched off enable the disabled non core plugin still in the "list"

Testing Instructions

use the prebuild https://artifacts.joomla.org/drone/joomla/joomla-cms/5.3-dev/44765/downloads/81566/

enable some non core plugin
Global Configuration -> System -> Debug

set safe mode on

image

Extensions: Manage check that all non core plugin are disabled

image

enable/update/delete etc a disabled plugin all works as usual

as example unistall one

Global Configuration -> System -> Debug

set safe mode off

all the previously disabled non core plugin still in the list are enabled

image

Actual result BEFORE applying this Pull Request

N/A

Expected result AFTER applying this Pull Request

a switch for disable / enable non core plugins

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

avatar alikon alikon - open - 21 Jan 2025
avatar alikon alikon - change - 21 Jan 2025
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 21 Jan 2025
Category SQL Administration com_admin Postgresql com_config Language & Strings Installation Libraries Front End Plugins
avatar alikon alikon - change - 21 Jan 2025
The description was changed
avatar alikon alikon - edited - 21 Jan 2025
01df20e 21 Jan 2025 avatar alikon cs
avatar alikon alikon - change - 21 Jan 2025
Labels Added: RFC Language Change PR-5.3-dev
66c1c70 21 Jan 2025 avatar alikon cs
avatar dgrammatiko
dgrammatiko - comment - 21 Jan 2025

@alikon nice work here. If I may I would like to propose another approach with less db stuff. We could use a reflection here to reset the plugins, in run time, similar to https://github.com/dgrammatiko/jailed-fs/blob/95444d8778e930a0360740e3b511b23bde374a5c/src/plugins/system/restrictedfs/src/Extension/RestrictedFS.php#L68-L78

You need to figure out what is essential and create the correct filter but should be an easier approach, ie not messing around with the real data in the db...

Also, I would use a URL parameter, ie joomla_safe_mode=true that will be checked by the plugin, together with the user permission, ie only users in the administrators group to activate the safe mode.

9be0c4c 22 Jan 2025 avatar alikon lang
7d7d6d5 23 Jan 2025 avatar alikon cs
avatar alikon alikon - change - 23 Jan 2025
The description was changed
avatar alikon alikon - edited - 23 Jan 2025
avatar alikon
alikon - comment - 23 Jan 2025

@dgrammatiko let's see 1st if it gets a consensus

avatar micker
micker - comment - 4 Feb 2025

ouahhhhhh great toooool, an idea for futur add step in upgrade to switch automatic to safe mode during update and propose to disable safe mode at ending process. That can be cool to protect upgrade process

avatar laoneo
laoneo - comment - 4 Feb 2025

Not sure if it helps, but HA has also such a "feature".

Add a Comment

Login with GitHub to post a comment