bart delvaux - deployments with magento 2

16
DEPLOYMENTS WITH MAGENTO 2 Tips & Tricks

Upload: dutchento

Post on 08-Jan-2017

252 views

Category:

Internet


2 download

TRANSCRIPT

Page 1: Bart Delvaux - Deployments with Magento 2

DEPLOYMENTS WITH MAGENTO 2Tips & Tricks

Page 2: Bart Delvaux - Deployments with Magento 2

BackgroundWhy deployments

Deployment in Magento 2

Questions

MENU

Page 3: Bart Delvaux - Deployments with Magento 2

BACKGROUNDMe, Myself & ISAAC

Page 4: Bart Delvaux - Deployments with Magento 2

MEBart Delvaux

ISAAC Software SolutionsPHP developerMagento specialistAuthor of

Magento 1.8 Development CookbookMagento 2 Development Cookbook

Page 5: Bart Delvaux - Deployments with Magento 2

ISAAC

Page 6: Bart Delvaux - Deployments with Magento 2

WHY DEPLOYMENTS

Page 7: Bart Delvaux - Deployments with Magento 2

Development setupWHY DEPLOYMENTS

Development UAT Live

Deployments to release new versions

Page 8: Bart Delvaux - Deployments with Magento 2

Minimal impact on production siteAutomated scriptMinimal downtime site

DEPLOYMENT

Page 9: Bart Delvaux - Deployments with Magento 2

MAGENTO 2Where to think about when deploying

Page 10: Bart Delvaux - Deployments with Magento 2

Deployment of code with composerGeneration of codeCSS compilation & generation of static filesInstall and upgrade scripts

DEPLOYMENT MAGENTO 2

Page 11: Bart Delvaux - Deployments with Magento 2

Possible to use composerComposer install before deployment

--no-dev--optimize-autoloader

Don’t use composer update

Private repositories?

COMPOSER

Page 12: Bart Delvaux - Deployments with Magento 2

Code is generated in var/generationOn the fly

Slower frontendPrepare as a background task

With command setup:di:compileUse the Magento production mode

With command deploy:mode:set

GENERATION OF CODE

Page 13: Bart Delvaux - Deployments with Magento 2

Static content is generated in folder pub/staticCan be generated on the fly

Long page speeds first timesWith the console command setup:static-content:deploy

Long processPossible to run in background

CSS AND STATIC CONTENT

Page 14: Bart Delvaux - Deployments with Magento 2

You need to run the install and upgrade scriptPut the site in maintenanceRun command setup:upgradeClean caches before going online

INSTALL AND UPGRADE SCRIPTS

Page 15: Bart Delvaux - Deployments with Magento 2

IN SHORTThink about deployments

Try to automateUse composerPrepare in the backgroundGo in maintenance for the crucial part

Page 16: Bart Delvaux - Deployments with Magento 2

QUESTIONS? [email protected]