samjuk/m2-module-auto-login-admin
Composer 安装命令:
composer require samjuk/m2-module-auto-login-admin
包简介
Automatically logins into the Admin panel, to a preset user
README 文档
README
This module removes the Authentication step to access the admin panel, instead directly logs into a pre defined user.
It is aimed to be run within development and/or ephemeral environments only.
Whilst the module has protections builtin to avoid running in production, this code should never make it there to begin with.
Installation
Installation may vary depending on your specific environment.
Composer Dev Dependency
The recommended approach to installing the module is via a composer dev dependency. This should prevent the module from being installed on production/pre-production environments.
composer require samjuk/m2-module-auto-login-admin php bin/magento module:enable SamJUK_AutoLoginAdmin
Manual
If for some reason your upstream environments are installing dev dependencies, you can opt for manual installation. Either at build time within your CI, or on the fly during deployment, by running the following from the project root.
[[ -d .git ]] && echo "app/code/SamJUK/AutoLoginAdmin" >> .git/info/exclude mkdir -p app/code/SamJUK git clone https://github.com/SamJUK/m2-module-auto-login-admin app/code/SamJUK/AutoLoginAdmin/ php bin/magento module:enable SamJUK_AutoLoginAdmin
Configuration
The default configuration of the module is to do nothing, even in development environments. With the potential risk involved, I deem, its better for the end user to be implicit in their intent to use this module.
That said, post installation, the module can be enabled with the following command.
php bin/magento config:set -e samjuk_auto_login_admin/general/auto_login 1
A full breakdown of the available configuration is listed within the table below.
| Config Path | Default | Description |
|---|---|---|
samjuk_auto_login_admin/general/auto_login |
0 |
Boolean flag to enable the module |
samjuk_auto_login_admin/general/username |
admin |
Admin username to Auto Login as |
samjuk_auto_login_admin/general/skip_production_mode_check |
0 |
Boolean flag, for if the module should run in production mode. |
samjuk/m2-module-auto-login-admin 适用场景与选型建议
samjuk/m2-module-auto-login-admin 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 1.01k 次下载、GitHub Stars 达 1, 最近一次更新时间为 2025 年 01 月 26 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 samjuk/m2-module-auto-login-admin 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 samjuk/m2-module-auto-login-admin 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 1.01k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 4
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2025-01-26