Looking to hire Laravel developers? Try LaraJobs

pentangle-laravel-backup-config maintained by pentangle

Description
An in house package for configuring backups with s3
Last update
2022/03/28 15:47 (dev-backpack_5_laravel_9_support)
License
Downloads
631

Comments
comments powered by Disqus

An in house package for configuring backups with s3

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

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.