Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
miguilimzero committed Aug 8, 2023
1 parent 461e7ae commit a22f2e8
Showing 1 changed file with 36 additions and 1 deletion.
37 changes: 36 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ SINGLESTORE_BACKUP_DRIVER=
# Local storage
SINGLESTORE_BACKUP_PATH=
# S3 storage
# S3 storage (optionals)
SINGLESTORE_BACKUP_REGION=
SINGLESTORE_BACKUP_MULTIPART_CHUNK_SIZE=
SINGLESTORE_BACKUP_FORCE_PATH_STYLE=
Expand Down Expand Up @@ -88,9 +88,44 @@ php artisan singlestore:backup --differential

## Advanced Usage

Sometimes the simple backup command with configs may not be flexible as you want. Instead, you can use the `SinglestoreBackup` class:

```php
use Miguilim\LaravelSinglestoreBackup\SinglestoreBackup;

$backupInstance = new SinglestoreBackup(
driver: 'local',
database: 'mydatabase',
path: '/my-backup/path'
);

$result = $backupInstance->executeQuery();
```

Available arguments:

- `driver`
- `database`
- `path`
- `endpoint`
- `timeout`
- `publicKey`
- `secretKey`
- `bucket`
- `init`
- `differential`
- `region`
- `multipartChunkSizeMb`
- `s3ForcePathStyle`

## Publishing Config File

You can publish the package configuration file to your project with the following command:

```sh
php artisan vendor:publish --tag=singlestore-backup-config
```

## License

Laravel SingleStore Backup is open-sourced software licensed under the [MIT license](LICENSE).

0 comments on commit a22f2e8

Please sign in to comment.