laravel-firestore-cache maintained by ivan770
Cloud Firestore cache for Laravel
Installation
composer require ivan770/laravel-firestore-cache
Configuration
- Register service provider in
config/app.php
Ivan770\Firestore\FirestoreServiceProvider::class,
- Add
firestoreconfig toconfig/cache.php
'firestore' => [
'driver' => 'firestore',
'id' => env('FIRESTORE_ID'),
'key' => env('GOOGLE_APPLICATION_CREDENTIALS'),
'collection' => env("FIRESTORE_COLLECTION", 'cache'),
]
- Configure your .env
CACHE_DRIVER=firestore
FIRESTORE_ID=project_id
GOOGLE_APPLICATION_CREDENTIALS=path_to_key_file