定制 maximkou/laravel-opcache-clear 二次开发

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

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

maximkou/laravel-opcache-clear

Composer 安装命令:

composer require maximkou/laravel-opcache-clear

包简介

This Laravel package allows you to clear the OPcache of a PHP application running in FPM mode with ease.

README 文档

README

This Laravel 5 package allows you to clear OPcache, solving a common problem related to cache invalidation during atomic deployments (also called "zero downtime deploy").

Getting Started

These instructions allows you to install the package into an existing Laravel app.

Prerequisities

Laravel 5 up&running installation.

Installation

You can install this package via Composer using:

composer require maximkou/laravel-opcache-clear

You must also install this service provider.

// config/app.php
'providers' => [
    ...
    Maximkou\LaravelOpcacheClear\OpcacheClearServiceProvider::class,
    ...
];

Check that url and key options is right defined in your config/app.php, example:

// config/app.php
'url' => env('APP_URL', 'http://my-app-url'),
'key' => env('APP_KEY'),

Usage

Once you have installed the package, you can run the following command (usually after deploy):

php artisan opcache:clear

All done! Your OPcache is resetted!

Customizations

Publish package config, if not published:

php artisan vendor:publish --provider="Maximkou\LaravelOpcacheClear\OpcacheClearServiceProvider"

All settings is placed in config/laravel-opcache-clear.php

  • Change uri of cleaner action by editing uri_slug option (by default is opcache-clear).
  • Change guzzle client options by editing guzzle_options options, to example, for disabling ssl verification:
'guzzle_options' => [
    'verify' => false,
]

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-01-09

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固