mirror of
https://github.com/v2board/v2board.git
synced 2024-11-10 09:39:10 +08:00
update: install random password
This commit is contained in:
parent
5976bcc65a
commit
4398f05b91
@ -89,16 +89,15 @@ class V2boardInstall extends Command
|
|||||||
while (!$email) {
|
while (!$email) {
|
||||||
$email = $this->ask('请输入管理员邮箱?');
|
$email = $this->ask('请输入管理员邮箱?');
|
||||||
}
|
}
|
||||||
$password = '';
|
$password = Helper::guid(false);
|
||||||
while (!$password) {
|
|
||||||
$password = $this->ask('请输入管理员密码?');
|
|
||||||
}
|
|
||||||
if (!$this->registerAdmin($email, $password)) {
|
if (!$this->registerAdmin($email, $password)) {
|
||||||
abort(500, '管理员账号注册失败,请重试');
|
abort(500, '管理员账号注册失败,请重试');
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->info('一切就绪');
|
$this->info('一切就绪');
|
||||||
$this->info('访问 http(s)://你的站点/admin 进入管理面板');
|
$this->info("管理员邮箱:{$email}");
|
||||||
|
$this->info("管理员密码:{$password}");
|
||||||
|
$this->info('访问 http(s)://你的站点/admin 进入管理面板,你可以用户中心修改你的密码,请设置安全复杂的密码。');
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
$this->error($e->getMessage());
|
$this->error($e->getMessage());
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user