cancel
Showing results for 
Search instead for 
Did you mean: 

How to upgrade from 2.0.0 when installed to /pub via zip

How to upgrade from 2.0.0 when installed to /pub via zip

If we installed a Magento 2.0.0 store via the downloadable zip, but we set the root web directory to /pub (as is recommended for security), this removes the ability to use the web based update feature in the admin panel.

 

What is the method via the command line to upgrade to 2.0.1? Or do we have to download the zip and upgrade by overwriting files by unzipping? Not sure what the recommended approach is. Thanks.

8 REPLIES 8

Re: How to upgrade from 2.0.0 when installed to /pub via zip

You should be able to go to  "Admin->System->Web setup wizard->System upgrade" and follow steps as specified here

Re: How to upgrade from 2.0.0 when installed to /pub via zip

Unfortunately, if you install Magento with a web root of "/pub", this is not an option. This is the recommended install for security according to the docs. The downside is the web based updater is no longer available. When you try to go to it, it goes to a 404.

Re: How to upgrade from 2.0.0 when installed to /pub via zip

So I went ahead and untarred the Magento 2.0.1 tar.gz file in the web directory, then I ran:

 

bin/magento setup:upgrade
bin/magento cache:flush

Is this the approved way to upgrade a Magento store that has its root web directory set to /pub, and was initially installed from the distributed tar.gz file?

Re: How to upgrade from 2.0.0 when installed to /pub via zip

As a follow up, it seems the correct way to upgrade in this case is to use "composer update", first updating the composer.json file to change the base package version from 2.0.0 to 2.0.1. Reference:

 

http://magento.stackexchange.com/questions/98407/update-magento-2-using-composer-update-cli

 

Re: How to upgrade from 2.0.0 when installed to /pub via zip

Hi Rob. Do you think this unpack/upgrade/flush + .json edit would work for an install not in /pub that I can't get the updater working with?

 

Thanks,

 

Paul

Re: How to upgrade from 2.0.0 when installed to /pub via zip

Paul,

 

The accepted way is to run "composer update" after editing the composer.json file in the root Magento directory. See this thread for how I got it to work if you run into an error:

http://magento.stackexchange.com/questions/98407/update-magento-2-using-composer-update-cli

 

Re: How to upgrade from 2.0.0 when installed to /pub via zip

Hi Rob,

 

Thanks for replying. I've tried tweaking the .json file as suggested, but I'm still getting the same issue: I run the upgrade tool, select a Magento version, start the readiness check and get a component dependency conflict. Having done lots of searching, it would appear that I'm not the only one to be having the problem, but I guess it's usually the case when new functionality rolls out to a wider audience... Smiley Wink

 

Paul

Re: How to upgrade from 2.0.0 when installed to /pub via zip

Yes, it does seem to be a bug. If you have ssh, try running the "composer update" command via ssh in the root directory of Magento after adjusting the line in composer.json and see if that works. You may need to create a few .gitignore files for the process to complete.