Looking to hire Laravel developers? Try LaraJobs

laravel-migration-loadbalancer maintained by netsells

Author
Last update
2020/07/14 09:46 (dev-master)
License
Downloads
22
Tags

Comments
comments powered by Disqus

Laravel Migration Loadbalancer

Provides middleware that returns a 503 should there be any migrations that need migrating. This is to be used with a loadbalancer so that only the correct codebase is live when the database migrates.

See https://engineering.instawork.com/elegant-database-migrations-on-ecs-74f3487da99f

Installation

You can install the package via composer:

composer require netsells/laravel-migration-loadbalanceer

Usage

Laravel will auto-load the service provider. All you need to do is add the global middleware to the top of your stack in app/Http/Kernel.php.

protected $middleware = [
    \Netsells\MigrationLb\HandleMigrationLbMiddleware::class,
    // Other middleware
];

Security

If you discover any security related issues, please email sam@netsells.co.uk instead of using the issue tracker.

License

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