coreblue/

moat

此包的最新版本(v1.0)没有可用的许可信息。

用密码保护您的预发布网站

v1.0 2018-10-03 07:40 UTC

This package is not auto-updated.

Last update: 2024-09-26 16:57:10 UTC


README

此包使您轻松地用密码保护您的Laravel预发布网站。

安装

您可以通过composer安装此包

composer require coreblue/moat

设置

在应用程序的路由中间件组中注册Moat中间件。

//app/http/Kernel.php
protected $middlewareGroups = [
    'web' => [
        \CoreBlue\Moat\Middleware\ApplyMoat::class,
    ],
];

使用方法

要开始使用Moat,请运行以下命令。

php artisan moat:create

运行创建命令后,您将能够运行以下命令。


您可以通过以下方式启用Moat

php artisan moat:up

您可以通过以下方式禁用Moat

php artisan moat:down

您可以通过以下方式设置新的密码

php artisan moat:password

您可以通过以下方式检查当前状态

php artisan moat:status