jalogut / magento2-deployer-plus

Tool based on deployer.org to perform zero downtime deployments of Magento 2 projects
GNU General Public License v3.0
200 stars 60 forks source link

Closes #40. Enhancement: Run Composer optimize autoloader after DI compile. #51

Closed erfanimani closed 4 years ago

erfanimani commented 4 years ago

I'm merging into master since develop seems behind.

Disclaimer — I haven't run this in production yet, so give me a few days and I'll can confirm on my end if this works.

sprankhub commented 4 years ago

Awesome, thanks!

I am always confused regarding the file structure in this repo. So... Does this also work for 2.2 and 2.3 deployments?

erfanimani commented 4 years ago

Haha same here. Yeah, 2.1 is inherited by both 2.2 and 2.3. (Although I probably won't test it with 2.1 or 2.2, it should work with previous versions of Magento)

erfanimani commented 4 years ago

I made some changes, and it's working properly now. Tested on two projects.

To test, after a deployment open up vendor/composer/autoload_classmap.php and ensure classes exist that are located in /generated/code (should be a couple thousand occurrences)

osrecio commented 4 years ago

Thanks @erfanimani I will merge as soon as possible.

I would also like to take the opportunity to remove the support for Magento 2.0 and 2.1 as Magento itself does not support them.

Taking advantage of that. I will think about how to simplify the repository structure to make it clearer.

erfanimani commented 4 years ago

Thanks @osrecio , much appreciated

osrecio commented 4 years ago

Your PR is merged @erfanimani

Release 2.7.0