Log in from magento cli?
-
14-04-2021 - |
문제
On Drupal I often log in using drush uli
. It opens a one-time login URL in my browser.
Is it possible to log in to the Magento backend with bin/magento
?
해결책
No, It is not possible currently to log in as an admin using CLI in Magento 2 but you can create a new user like:
php bin/magento admin:user:create --admin-user=mageuser --admin-password=HiMagento123 --admin-email=user@example.com --admin-firstname=John --admin-lastname=Doe
Or you can check the below command for more details:
php bin/magento admin:user:create --help
다른 팁
Natively, I don't think that is possible, you can rather see the admin URI like this : php bin/magento info:adminuri
To see all the available commands, you can execute : php bin/magento
or php bin/magento list
.
제휴하지 않습니다 magento.stackexchange