Can't make changes to db_default
#28
Replies: 4 comments 6 replies
-
Unfortunately the current solution with The only way to fix it (allow It would be nice to have it improved but I am afraid the side effects overcome the gains. So for now the way you do it now - means redeclare |
Beta Was this translation helpful? Give feedback.
-
Hey @kszymukowicz Sorry to bring this up again. I was trying to add some tables to the I have the following in my set(
'db_default',
[
// Ignore tables
'ignore_tables_out' => [
'cf_.*',
'cache_.*',
'be_sessions',
'fe_sessions',
'fe_session_data',
'sys_file_processedfile',
'sys_history',
'sys_log',
'sys_refindex',
// Custom additions
'tx_kesearch_index',
'tx_simplelog404_domain_model_logentry',
],
// Delete non-liquid light users & remove MFA
'post_sql_in' => '
UPDATE be_users SET mfa = "";
',
]
);
// Needs to be redeclared to reset the variable from above
set('db_databases', [
'database_default' => [
get('db_default'),
function () {
return (new \SourceBroker\DeployerExtendedTypo3\Drivers\Typo3CmsDriver())->getDatabaseConfig();
},
],
]); Despite this, Thanks |
Beta Was this translation helpful? Give feedback.
-
hi @mikestreety what I am doing is
|
Beta Was this translation helpful? Give feedback.
-
Maybe you switched from 19 to 20? |
Beta Was this translation helpful? Give feedback.
-
Yo!
I was wanting to make some changes to the
db_default
variable (add some SQL topost_sql_in
) which is set in each version's set.php.Sidenote: I realise this code is actually called in deployer-extended-typo3, however it is the implementation in this package which is causing the issue
It seems because the variable is then used inside the
db_databases
, it seems it gets cached and you cannot override without then overridingdb_databases
.My current solution is the following: (I have managed to reduce
db_databases
as I want to use the TYPO3 CMS Driver)Is there anyway the script can re-evaluate at runtime or similar (or can we get a second, empty array which gets array merged) later on inside the
extended-db
package?Happy to create an MR where it is needed, but would appreciate guidance on how and where
Beta Was this translation helpful? Give feedback.
All reactions