docker-magento
docker-magento copied to clipboard
Warning from repo.magento.com: Your Magento authentication keys are invalid.
Description 1st install i failed to enter the correct authentication credentials, right now install is no longer possible.
An update on documentation should suffice (~/.composer/auth.json
)
Steps To Reproduce
- Install with wrong credentials
Expected Result Re-enter credentials
Actual Result
Creating a "magento/project-community-edition=2.4.6-p4" project at "./"
Warning from repo.magento.com: Your Magento authentication keys are invalid. Please double-check your keys in your Marketplace account. For instructions, visit https://devdocs.magento.com/guides/v2.3/install-gde/prereq/connect-auth.html
In AuthHelper.php line 205:
The 'https://repo.magento.com/packages.json' URL required authentication (H
TTP 401).
You must be using the interactive console to authenticate
It's because the container already exists cached auth.json
with the wrong credentials.
There are 2 ways to fix this issue:
1 Way (IMHO better than 2):
-
Drop inside the docker container
bin/bash
-
Now, you can see the file which is called
auth.json.sample
, you should paste your public and private keys in this filevim auth.json.sample
-
Rename the file from
auth.json.sample
toauth.json
2 Way (Re-install):
-
Delete the file with the incorrectly cached credentials:
rm ~/.composer/auth.json
-
Clean up the failed install:
bin/removeall
-
Delete the files left behind by the failed install:
cd ..
followed byrm -rf yourpoject
Then, create your new project directory again so you can attempt the install process again. The bin/removeall command removes all previous Docker containers & volumes related to the specific project directory you are within. You can then attempt the installation process again.
Yeah i know.. i wasn't really clear :)
Already mentioned a documentation update should suffice..
But tnxx for your quick reply !