pentangle / pentangle-laravel-backup-config
An in house package for configuring backups with s3
Fund package maintenance!
Pentangle
Requires
- php: ^8.0
- backpack/backupmanager: ^3.0
- backpack/crud: 4.1.*
- illuminate/support: ^8.0
- league/flysystem-aws-s3-v3: ~1.0
- spatie/laravel-package-tools: ^1.9
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.17
- phpunit/phpunit: ^9.5
- roave/security-advisories: dev-latest
- spatie/ray: ^1.10
- vimeo/psalm: ^4.3
README
Installation
You can install the package via composer:
composer require pentangle/pentangle-laravel-backup-config
Usage
Add the following disk configuration to filesystems.php
'pentangle-s3' => [ 'driver' => 's3', 'key' => env('PENTANGLE_AWS_ACCESS_KEY_ID'), 'secret' => env('PENTANGLE_AWS_SECRET_ACCESS_KEY'), 'region' => env('PENTANGLE_AWS_DEFAULT_REGION'), 'bucket' => env('PENTANGLE_AWS_BUCKET'), 'url' => env('PENTANGLE_AWS_URL'), 'endpoint' => env('PENTANGLE_AWS_ENDPOINT'), 'root' => str_replace(['http://', 'https://'], '', env('APP_URL', 'example.com')), ],
Add the following service provider to config/app.php (optional)
\Pentangle\PentangleLaravelBackupConfig\PentangleLaravelBackupServiceProvider::class,
Publish the config file (optional)
php artisan vendor:publish --provider="Pentangle\PentangleLaravelBackupConfig\PentangleLaravelBackupServiceProvider"
For testing locally with s3 ensure the correct path to mysqldump is set in config/databases.php
'dump' => [ 'dump_binary_path' => env('APP_ENV') === 'local' ? '/usr/local/opt/mysql-client/bin' : '/usr/bin', ],
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.