Wrap docker management in a convenient Laravel package, just like Sail but with a different approach. Also make it usable in production. Laravel Sail is nice, but fails on one of the biggest promises of Docker: consistency between environments, a.k.a. build once, run everywhere.
Awesome comic by Julia Evans, please consider supporting her
- To enable all features in Laravel with the help of external services
- To configure this package with just a config file
- To support multiple environments with different services (e.g. xDebug in development)
- To create smaller images than Sail by using Alpine based Linux images
- Let's Encrypt support
- docker-sync on Mac host
composer require thomasmoors/anchor
https://thomasmoors.github.io/anchor/
php artisan vendor:publish --provider="Thomasmoors\Anchor\AnchorServiceProvider" --tag="anchor-migrations"
php artisan migrate
You can publish the config file with:
php artisan vendor:publish --provider="Thomasmoors\Anchor\AnchorServiceProvider" --tag="anchor-config"
As most things Docker related get a nautical term or at least something related to boats, I thought it to be a good idea to use Anchor. As a bonus just like docker-compose you now can execute anchor up
and anchor down
which does exactly the same to the containers as it would do to a boat. 🙂
$anchor = new Thomasmoors\Anchor();
echo $anchor->echoPhrase('Hello, Spatie!');
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
Please review our security policy on how to report security vulnerabilities.
The MIT License (MIT). Please see License File for more information.