定制 laramicstudio/env-guard 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

laramicstudio/env-guard

最新稳定版本:1.60.0

Composer 安装命令:

composer require laramicstudio/env-guard

包简介

It lets you define a schema for your .env file — think of it like a contract. When your app boots, it checks your actual .env against that contract and fails loudly and early if something is wrong.It lets you define a schema for your .env file — think of it like a contract. When your app boots, it c

README 文档

README

App Screenshot

ENV-GUARD

lets you define a schema for your .env file — think of it like a contract. When your app boots, it checks your actual .env against that contract and fails loudly and early if something is wrong.

composer require laramicstudio/env-guard

You can publish the config file with:

php artisan vendor:publish --tag="env-guard-config"

If you are installing on a already existing project you can run the command

php artisan env:check

This is the contents of the published config file:

return [

    'log_rejections' => false,

    'log_channel' => 'stack',

    'rules' => [
        'APP_KEY' => 'required|string',
        'APP_ENV' => 'required|in:local,staging,production',
        'DB_PASSWORD' => 'required|string|min:8',
        'STRIPE_SECRET' => 'required|starts_with:sk_',
        'CACHE_TTL' => 'required|integer|min:1',
        'MAIL_PORT' => 'nullable|integer',
    ],
];

Usage

$envGuard = new LaramicStudio\EnvGuard();
$envGuard->validate();

Testing

composer test

Contributing

Please see CONTRIBUTING for details.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 5
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 5
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-03-09

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固