ivan770/laravel-firestore-cache

Cloud Firestore driver for Laravel cache

dev-master 2019-05-31 07:20 UTC

This package is auto-updated.

Last update: 2024-04-29 04:06:38 UTC


README

Installation

composer require ivan770/laravel-firestore-cache

Configuration

  1. Register service provider in config/app.php
Ivan770\Firestore\FirestoreServiceProvider::class,
  1. Add firestore config to config/cache.php
'firestore' => [
    'driver' => 'firestore',
    'id' => env('FIRESTORE_ID'),
    'key' => env('GOOGLE_APPLICATION_CREDENTIALS'),
    'collection' => env("FIRESTORE_COLLECTION", 'cache'),
]
  1. Configure your .env
CACHE_DRIVER=firestore
FIRESTORE_ID=project_id
GOOGLE_APPLICATION_CREDENTIALS=path_to_key_file

Usage

Laravel documentation