Troubleshoot deployment
This topic discusses how to recover if you deployed the Magento application with the incorrect Magento authentication keys. For example, you might have used the keys for another account or you might have used Magento Open Source keys instead of Magento Commerce keys.
If you used the incorrect keys, deployment fails. To recover, you must clone the project, add the correct keys to auth.json
, and push the change to the master branch.
In this section, we assume that your project has a master
branch only (master
is the default branch when you first create a project).
To redeploy with the correct authentication keys:
- Log in to the machine that has your Magento Commerce Cloud SSH keys.
-
Log in to the project:
1
magento-cloud login
-
Create a branch to update code with the name
auth
:magento-cloud environment:branch auth master
- Change to the project root directory.
-
Open
auth.json
in a text editor.1 2 3 4 5 6 7 8
{ "http-basic": { "repo.magento.com": { "username": "<your public key>", "password": "<your private key>" } } }
- Add the correct authentication keys.
- Save your changes and exit the text editor.
-
Commit and merge your changes.
1
git add -A
1
git commit -m "<description of change>"
1
git push origin master
- Wait for the deployment to complete.
Messages indicate whether deployment was successful. You can confirm a successful deployment by going to one of the Environment routes displayed on your screen.