Skip to content

Simple Backblaze Laravel adapter with token caching.

License

Notifications You must be signed in to change notification settings

Leme7/backblaze

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Backblaze Laravel Adapter

Setup:

composer require amelia/backblaze

Register Amelia\Backblaze\BackblazeServiceProvider::class, then add a config array in filesystems.php.

'b2' => [
    'driver' => 'b2',
    'key' => env('BACKBLAZE_KEY'),
    'host' => env('BACKBLAZE_HOST'),
    'bucket' => env('BACKBLAZE_BUCKET'),
    'account' => env('BACKBLAZE_ACCOUNT'),
],

host can be set if you want to link directly to files in buckets marked allPublic.

See this handy guide for setting up cloudflare page rules to turn your bucket into a CDN.

Features

  • Caches the auth token, meaning you don't constantly hit the auth endpoint.
  • Refreshes the auth token for long-running processes (like queue:work).

About

Simple Backblaze Laravel adapter with token caching.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%