- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
We need to upgrade a specific extension using composer, as the extension is inside vendor folder.
Would you tell me the right way to do it?
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can upgrade an extension using following way:
Upgrade an extension
You should have a branch to work in when updating your extension. These instructions use composer to update the files. Before you continue, you must:
Know the extension’s Composer name and version
Know the extension is compatible with your project and Magento Commerce Cloud version. In particular, check the required PHP version.
To update an extension:
If you haven’t done so already, change to your environment root directory.
Open composer.json in a text editor.
Locate your extension and update the version.
Save your changes to composer.json and exit the text editor.
Update project dependencies:
composer update
Enter the following commands in the order to commit the changes and deploy the project, including composer.lock:
git add -A
git commit -m "<MESSAGE>"
git push origin <ENVIRONMENT id="">
Wait for the project to deploy and verify in your environment.
If there are errors, see Component deployment failure.
For more info, you can magento document for it.
https://devdocs.magento.com/guides/v2.3/cloud/howtos/install-components.html
As summary: basically you need to your new version to composer and run composer update...
I hope it will help you!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Upgrade a specific extension from composer
You should upgrade extension using composer.
See composer.json file on the root of the extension to find the package name.
Run the composer update command line to upgrade:
Example:
composer update vendor/extension
Thanks
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can upgrade an extension using following way:
Upgrade an extension
You should have a branch to work in when updating your extension. These instructions use composer to update the files. Before you continue, you must:
Know the extension’s Composer name and version
Know the extension is compatible with your project and Magento Commerce Cloud version. In particular, check the required PHP version.
To update an extension:
If you haven’t done so already, change to your environment root directory.
Open composer.json in a text editor.
Locate your extension and update the version.
Save your changes to composer.json and exit the text editor.
Update project dependencies:
composer update
Enter the following commands in the order to commit the changes and deploy the project, including composer.lock:
git add -A
git commit -m "<MESSAGE>"
git push origin <ENVIRONMENT id="">
Wait for the project to deploy and verify in your environment.
If there are errors, see Component deployment failure.
For more info, you can magento document for it.
https://devdocs.magento.com/guides/v2.3/cloud/howtos/install-components.html
As summary: basically you need to your new version to composer and run composer update...
I hope it will help you!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Upgrade a specific extension from composer
Hi @Vimal Kumar @ChandrakeshK ,
Thanks for your replies.
I have accidentaly updated the extension by changing the version and running 'bin/magento setup:upgrade' on a testing site.
As this is using GitHub we don't really change files on their live site.
There is no files under 'vendor' folder on the repository.
Should we do the same on the live site? I am worried about down time.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Upgrade a specific extension from composer
Hi @mlacey
You definitely need to run command on server.
If we don't run php bin/magento setup:upgrade command on the live server. Database will never know then this extension is upgraded.
There are any entry exist in database table of extension version which is running.
You can check in "setup_module" table in the database.