PHPackages                             oh86/laravel-gw - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. oh86/laravel-gw

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

oh86/laravel-gw
===============

Laravel gateway

v1.1(1y ago)040MITPHPPHP ^7.4 || ^8.0

Since Jan 6Pushed 1y ago1 watchersCompare

[ Source](https://github.com/OneHundred86/laravel-gw)[ Packagist](https://packagist.org/packages/oh86/laravel-gw)[ RSS](/packages/oh86-laravel-gw/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (5)Versions (3)Used By (0)

### 基于laravel实现的网关服务

[](#基于laravel实现的网关服务)

#### 1.安装

[](#1安装)

```
composer install oh86/laravel-gw
php artisan vendor:publish --provider="Oh86\GW\GatewayServiceProvider"
```

#### 2.配置 gw.yaml

[](#2配置-gwyaml)

```
log_channel: daily  # 使用laravel的日志配置
routes:
  app1:
    name: 应用1
    access_log_channel:   # 缺省使用log_channel配置
    error_log_channel:    # 缺省使用log_channel配置
    route: /app1/api/{path}     # 必须，{path}为固定变量
    proxy_pass: http://localhost:8000/{path} # 必须，{path}为route配置的变量
    middlewares:  # laravel的中间件
      - Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull
    proxy_middelewares: # 代理中间件
      - Oh86\GW\ProxyMiddlewares\AllowRequestHeaders:cookie,accept
      - Oh86\GW\ProxyMiddlewares\AddRequestHeader:h1,v1
      - Oh86\GW\ProxyMiddlewares\SetXRealIPHeader
      - Oh86\GW\ProxyMiddlewares\SetXForwardedForHeader
      - Oh86\GW\ProxyMiddlewares\PrivateRequest:app1,ticket1
    proxy_timeout: 10
    circuit_breaker:  # {error_period}时间内错误超过{error_threshold}次，触发熔断，熔断时长为{break_period}
      error_period: 60
      error_threshold: 5
      break_period: 300
```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance43

Moderate activity, may be stable

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~42 days

Total

2

Last Release

449d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c3f893211000acbd1a600e2159a778865e4f7e54661239721c9fb5c240d7626b?d=identicon)[oh86](/maintainers/oh86)

---

Top Contributors

[![OneHundred86](https://avatars.githubusercontent.com/u/22148561?v=4)](https://github.com/OneHundred86 "OneHundred86 (22 commits)")

### Embed Badge

![Health badge](/badges/oh86-laravel-gw/health.svg)

```
[![Health](https://phpackages.com/badges/oh86-laravel-gw/health.svg)](https://phpackages.com/packages/oh86-laravel-gw)
```

###  Alternatives

[flarum/core

Delightfully simple forum software.

211.3M1.9k](/packages/flarum-core)[ralphjsmit/laravel-helpers

A package containing handy helpers for your Laravel-application.

13704.6k2](/packages/ralphjsmit-laravel-helpers)[aeliot/todo-registrar

Register TODOs from source code in issue tracker

153.0k](/packages/aeliot-todo-registrar)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

255.2k](/packages/aedart-athenaeum)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
