eZ Community » Forums » eZ Publish 5 Platform » Disable legacy extension after...
expandshrink

Disable legacy extension after composer install

Disable legacy extension after composer install

Thursday 11 December 2014 12:32:56 pm - 2 replies

Hello,
I used composer to install legacy extensions via my "AcmeLegacyBundle".
As expected legacy extensions are symlinked in ezpublish_legacy/extension and enabled (see vendor/ezsystems/ezpublish-kernel/doc/specifications/legacy_bundles/legacy_bundles.md )
Unfortunately I need some of these extensions not to be enabled by default. Is there's a way to bypass the auto activation process?
Thanks,
Julien 

Tuesday 28 February 2017 5:33:59 pm

+1

Same question happy.gif Emoticon

Saturday 04 March 2017 9:29:01 am

Hello Julien & Clément,

There are a few answers here that might help.

You could rename your extension.xml which would prevent autoloading via settings injection.

You could also in theory disable these extensions via yaml configuration (guess), "ezpublish_legacy.legacy_bundles_extensions":

https://github.com/ezsystems/LegacyBridge/blob/master/bundle/LegacyMapper/LegacyBundles.php#L80

https://github.com/ezsystems/LegacyBridge/blob/master/bundle/Resources/config/services.yml#L238

https://github.com/ezsystems/LegacyBridge/blob/master/bundle/DependencyInjection/Compiler/LegacyBundlesPass.php#L42

https://github.com/ezsystems/LegacyBridge/blob/master/bundle/Tests/DependencyInjection/Compiler/LegacyBundlesPassTest.php#L57

If the parameters described above is not able to be customize via yaml you could very simply override this above class to provide for a 'ezpublish_legacy.legacy-bundles_extensions_disabled' parameter array which could be checked to not inject a specific extension into the legacy active extensions settings array.

I hope this helps!

Cheers,
Heath

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from