Thanks to this great tutorial on how to extend Laravel’s storage to Google Drive, Gainslog now pushes daily updates to Google Drive.
Following the tutorial, one issue people run into is a
File not found error when running the backup command.
You can get around it by setting the backup folder name to an empty string – but that will place all the backup zip files directly into the
One way to make sure all backups go into a single folder is to setup a new local disk in
filesystem.php and update the
backup.php config to use that one instead.
// config/filesystems.php 'local' => [ 'driver' => 'local', 'root' => storage_path('app'), ], 'local-backups' => [ 'driver' => 'local', 'root' => storage_path('app/backups'), ],
// config/backup.php 'destination' => [ /* * The filename prefix used for the backup zip file. */ 'filename_prefix' => 'backup-', /* * The disk names on which the backups will be stored. */ 'disks' => [ 'local-backups', 'google' ], ],