Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Backup Laravel Package

spatie/laravel-backup

Spatie Laravel Backup creates zip backups of your app files and database, storing them on any Laravel filesystem (even multiple). Includes health monitoring, notifications, and automatic cleanup of old backups. Run with php artisan backup:run.

View on GitHub
Deep Wiki
Context7

title: Events weight: 2

These events are fired during the backup process.

BackupWasSuccessful

Spatie\Backup\Events\BackupWasSuccessful

This event is fired when the zip file containing all files that should be backed up has successfully been copied to a destination filesystem.

It has two public properties:

  • $diskName: a string containing the name of the destination disk.
  • $backupName: a string containing the name of the backup.

BackupHasFailed

Spatie\Backup\Events\BackupHasFailed

This event will be fired when something goes wrong while backing up.

It has three public properties:

  • $exception: an object that extends PHP's Exception class. It is highly likely that $exception->getMessage() will return more information on what went wrong.
  • $diskName: a nullable string containing the name of the destination disk. If this is null then something probably went wrong before the backup could be copied to a destination.
  • $backupName: a nullable string containing the name of the backup.

BackupManifestWasCreated

Spatie\Backup\Events\BackupManifestWasCreated

Internally the package will build up a manifest of files. This manifest contains the dumps of the databases and any files that are selected for backup. All the files in the manifest will be zipped.

It has one public property $manifest which is an instance of Spatie\Backup\Tasks\Backup\Manifest

BackupZipWasCreated

Spatie\Backup\Events\BackupZipWasCreated

This event will be fired right after the zipfile - containing the dumps of the databases and any files that were selected for backup - is created, and before that zip will get copied over to the backup destination(s). You can use this event to do last minute manipulations on the created zip file.

It has one public property $pathToZip which contains a path to the created zipfile.

DumpingDatabase

Spatie\Backup\Events\DumpingDatabase

This event will be fired before dumping the databases. You can use this event to do last minute manipulations on database dumper.

It has one public property $dbDumper which is an instance of a dumper driver.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
babenkoivan/elastic-client
innmind/static-analysis
innmind/coding-standard
datacore/hub-sdk
alengo/sulu-http-cache-bundle
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
imbo/imbo-coding-standard
visualbuilder/filament-lottie
servicioslineaonce/starter-kit
atomcoder/laravel-reorderable
irajul/filament-shadcn-theme
agtp/agtp-php
agtp/mod-php
centraldesktop/protobuf-php