1 頁 (共 1 頁)

sql backup

發表於 : 2017-09-15 14:57:08
yehlu
https://docs.spatie.be/laravel-backup/v5/introduction

代碼: 選擇全部

composer require spatie/laravel-backup
app/config

代碼: 選擇全部

Spatie\Backup\BackupServiceProvider::class,

代碼: 選擇全部

php artisan vendor:publish --provider="Spatie\Backup\BackupServiceProvider"
config/database.php

代碼: 選擇全部

            'dump' => [
        		   'dump_binary_path' => '/usr/local/bin/mysqldump', // only the path, so without `mysqldump` or `pg_dump`
        		   'use_single_transaction',
        		   'timeout' => 60 * 5, // 5 minute timeout
        		   //'exclude_tables' => ['table1', 'table2'],
        		   'add_extra_option' => '--optionname=optionvalue',
        		]